[BACK]Return to tty.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / tmux

Diff for /src/usr.bin/tmux/tty.c between version 1.317 and 1.318

version 1.317, 2019/03/14 09:50:09 version 1.318, 2019/03/14 09:53:52
Line 2498 
Line 2498 
 {  {
         struct window           *w = wp->window;          struct window           *w = wp->window;
         struct options          *oo = w->options;          struct options          *oo = w->options;
         const struct grid_cell  *agc, *pgc, *wgc;          struct style            *active, *pane, *window;
         int                      c;          int                      c;
   
         if (w->flags & WINDOW_STYLECHANGED) {          if (w->flags & WINDOW_STYLECHANGED) {
                 w->flags &= ~WINDOW_STYLECHANGED;                  w->flags &= ~WINDOW_STYLECHANGED;
                 agc = options_get_style(oo, "window-active-style");                  active = options_get_style(oo, "window-active-style");
                 memcpy(&w->active_style, agc, sizeof w->active_style);                  style_copy(&w->active_style, active);
                 wgc = options_get_style(oo, "window-style");                  window = options_get_style(oo, "window-style");
                 memcpy(&w->style, wgc, sizeof w->style);                  style_copy(&w->style, window);
         } else {          } else {
                 agc = &w->active_style;                  active = &w->active_style;
                 wgc = &w->style;                  window = &w->style;
         }          }
         pgc = &wp->colgc;          pane = &wp->style;
   
         if (gc->fg == 8) {          if (gc->fg == 8) {
                 if (pgc->fg != 8)                  if (pane->gc.fg != 8)
                         gc->fg = pgc->fg;                          gc->fg = pane->gc.fg;
                 else if (wp == w->active && agc->fg != 8)                  else if (wp == w->active && active->gc.fg != 8)
                         gc->fg = agc->fg;                          gc->fg = active->gc.fg;
                 else                  else
                         gc->fg = wgc->fg;                          gc->fg = window->gc.fg;
   
                 if (gc->fg != 8) {                  if (gc->fg != 8) {
                         c = window_pane_get_palette(wp, gc->fg);                          c = window_pane_get_palette(wp, gc->fg);
Line 2529 
Line 2529 
         }          }
   
         if (gc->bg == 8) {          if (gc->bg == 8) {
                 if (pgc->bg != 8)                  if (pane->gc.bg != 8)
                         gc->bg = pgc->bg;                          gc->bg = pane->gc.bg;
                 else if (wp == w->active && agc->bg != 8)                  else if (wp == w->active && active->gc.bg != 8)
                         gc->bg = agc->bg;                          gc->bg = active->gc.bg;
                 else                  else
                         gc->bg = wgc->bg;                          gc->bg = window->gc.bg;
   
                 if (gc->bg != 8) {                  if (gc->bg != 8) {
                         c = window_pane_get_palette(wp, gc->bg);                          c = window_pane_get_palette(wp, gc->bg);

Legend:
Removed from v.1.317  
changed lines
  Added in v.1.318