1: #ifndef lint
   2: static char sccsid[] = "@(#)cmd3.c	3.13 4/24/85";
   3: #endif
   4: 
   5: /*
   6:  * Copyright (c) 1983 Regents of the University of California,
   7:  * All rights reserved.  Redistribution permitted subject to
   8:  * the terms of the Berkeley Software License Agreement.
   9:  */
  10: 
  11: #include "defs.h"
  12: #include "string.h"
  13: 
  14: c_close(w)
  15: register struct ww *w;
  16: {
  17:     char didit = 0;
  18:     register i;
  19: 
  20:     if (w != 0) {
  21:         closewin(w);
  22:         didit++;
  23:     } else {
  24:         for (i = 0; i < NWINDOW; i++) {
  25:             if ((w = window[i]) == 0)
  26:                 continue;
  27:             closewin(w);
  28:             didit++;
  29:         }
  30:     }
  31:     if (selwin == 0) {
  32:         if (lastselwin != 0)
  33:             setselwin(lastselwin);
  34:         else {
  35:             for (i = 0; i < NWINDOW && window[i] == 0; i++)
  36:                 ;
  37:             if (i < NWINDOW)
  38:                 setselwin(window[i]);
  39:         }
  40:     }
  41:     if (didit)
  42:         reframe();
  43: }
  44: 
  45: setescape(esc)
  46: register char *esc;
  47: {
  48:     if (*esc == '^') {
  49:         if (esc[1] != 0)
  50:             escapec = esc[1] & 0x1f;
  51:         else
  52:             escapec = '^';
  53:     } else
  54:         escapec = *esc;
  55: }
  56: 
  57: setlabel(w, label)
  58: register struct ww *w;
  59: char *label;
  60: {
  61:     if (w->ww_label != 0)
  62:         str_free(w->ww_label);
  63:     if ((w->ww_label = str_cpy(label)) == 0)
  64:         return -1;
  65:     return 0;
  66: }

Defined functions

c_close defined in line 14; used 4 times
setescape defined in line 45; used 2 times
setlabel defined in line 57; used 3 times

Defined variables

sccsid defined in line 2; never used
Last modified: 1985-04-25
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 1017
Valid CSS Valid XHTML 1.0 Strict