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

Diff for /src/usr.bin/tmux/window.c between version 1.220 and 1.221

version 1.220, 2019/03/14 09:50:09 version 1.221, 2019/03/14 09:53:52
Line 470 
Line 470 
 void  void
 window_redraw_active_switch(struct window *w, struct window_pane *wp)  window_redraw_active_switch(struct window *w, struct window_pane *wp)
 {  {
         const struct grid_cell  *gc;          struct style    *sy;
   
         if (wp == w->active)          if (wp == w->active)
                 return;                  return;
Line 479 
Line 479 
          * If window-style and window-active-style are the same, we don't need           * If window-style and window-active-style are the same, we don't need
          * to redraw panes when switching active panes.           * to redraw panes when switching active panes.
          */           */
         gc = options_get_style(w->options, "window-active-style");          sy = options_get_style(w->options, "window-active-style");
         if (style_equal(gc, options_get_style(w->options, "window-style")))          if (style_equal(sy, options_get_style(w->options, "window-style")))
                 return;                  return;
   
         /*          /*
          * If the now active or inactive pane do not have a custom style or if           * If the now active or inactive pane do not have a custom style or if
          * the palette is different, they need to be redrawn.           * the palette is different, they need to be redrawn.
          */           */
         if (window_pane_get_palette(w->active, w->active->colgc.fg) != -1 ||          if (window_pane_get_palette(w->active, w->active->style.gc.fg) != -1 ||
             window_pane_get_palette(w->active, w->active->colgc.bg) != -1 ||              window_pane_get_palette(w->active, w->active->style.gc.bg) != -1 ||
             style_equal(&grid_default_cell, &w->active->colgc))              style_is_default(&w->active->style))
                 w->active->flags |= PANE_REDRAW;                  w->active->flags |= PANE_REDRAW;
         if (window_pane_get_palette(wp, wp->colgc.fg) != -1 ||          if (window_pane_get_palette(wp, wp->style.gc.fg) != -1 ||
             window_pane_get_palette(wp, wp->colgc.bg) != -1 ||              window_pane_get_palette(wp, wp->style.gc.bg) != -1 ||
             style_equal(&grid_default_cell, &wp->colgc))              style_is_default(&wp->style))
                 wp->flags |= PANE_REDRAW;                  wp->flags |= PANE_REDRAW;
 }  }
   
Line 826 
Line 826 
   
         wp->saved_grid = NULL;          wp->saved_grid = NULL;
   
         memcpy(&wp->colgc, &grid_default_cell, sizeof wp->colgc);          style_set(&wp->style, &grid_default_cell);
   
         screen_init(&wp->base, sx, sy, hlimit);          screen_init(&wp->base, sx, sy, hlimit);
         wp->screen = &wp->base;          wp->screen = &wp->base;

Legend:
Removed from v.1.220  
changed lines
  Added in v.1.221