From 38e68e552e93c6b6eb19e50e0546c22138f68755 Mon Sep 17 00:00:00 2001 From: ayin Date: Wed, 6 Feb 2008 01:29:19 +0000 Subject: [PATCH] Remove missed occurrences of scrollbar_is{Up,Dn}. --- src/scrollbar-next.C | 4 ++-- src/scrollbar-rxvt.C | 7 +++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/scrollbar-next.C b/src/scrollbar-next.C index 388413bb..64364399 100644 --- a/src/scrollbar-next.C +++ b/src/scrollbar-next.C @@ -282,12 +282,12 @@ rxvt_term::scrollbar_show_next (int update, int last_top, int last_bot, int scro height - SB_BUTTON_SINGLE_HEIGHT, SB_BUTTON_WIDTH, SB_BUTTON_HEIGHT); - s = (scrollbar_isUp ()) ? upArrowHi : upArrow; + s = scrollBar.state == STATE_UP ? upArrowHi : upArrow; XCopyArea (dpy, s, scrollBar.win, whiteGC, 0, 0, ARROW_WIDTH, ARROW_HEIGHT, SB_BUTTON_FACE_X, height - SB_BUTTON_BOTH_HEIGHT + SB_BEVEL_WIDTH_UPPER_LEFT); - s = (scrollbar_isDn ()) ? downArrowHi : downArrow; + s = scrollBar.state == STATE_DOWN ? downArrowHi : downArrow; XCopyArea (dpy, s, scrollBar.win, whiteGC, 0, 0, ARROW_WIDTH, ARROW_HEIGHT, SB_BUTTON_FACE_X, height - SB_BUTTON_SINGLE_HEIGHT + SB_BEVEL_WIDTH_UPPER_LEFT); diff --git a/src/scrollbar-rxvt.C b/src/scrollbar-rxvt.C index 216e0714..cfe826c0 100644 --- a/src/scrollbar-rxvt.C +++ b/src/scrollbar-rxvt.C @@ -151,6 +151,7 @@ rxvt_term::scrollbar_show_rxvt (int update, int last_top, int last_bot, int scro { int sbshadow = scrollBar.shadow; int sbwidth = (int)scrollBar.width; + int state; if ((scrollBar.init & R_SB_RXVT) == 0) { @@ -217,8 +218,10 @@ rxvt_term::scrollbar_show_rxvt (int update, int last_top, int last_bot, int scro draw_shadow (this, sbshadow, scrollBar.top, sbwidth, scrollbar_len); /* Redraw scrollbar arrows */ - draw_button (this, sbshadow, sbshadow, (scrollbar_isUp () ? -1 : +1), UP); - draw_button (this, sbshadow, scrollBar.end + 1, (scrollbar_isDn () ? -1 : +1), DN); + state = scrollBar.state == STATE_UP ? -1 : +1; + draw_button (this, sbshadow, sbshadow, state, UP); + state = scrollBar.state == STATE_DOWN ? -1 : +1; + draw_button (this, sbshadow, scrollBar.end + 1, state, DN); return 1; } -- 2.34.1