… | |
… | |
1240 | * direction should be UP or DN |
1240 | * direction should be UP or DN |
1241 | */ |
1241 | */ |
1242 | void |
1242 | void |
1243 | rxvt_term::scr_index (enum page_dirn direction) NOTHROW |
1243 | rxvt_term::scr_index (enum page_dirn direction) NOTHROW |
1244 | { |
1244 | { |
1245 | int dirn; |
|
|
1246 | |
|
|
1247 | want_refresh = 1; |
1245 | want_refresh = 1; |
1248 | ZERO_SCROLLBACK (); |
1246 | ZERO_SCROLLBACK (); |
1249 | |
1247 | |
1250 | dirn = ((direction == UP) ? 1 : -1); |
|
|
1251 | |
|
|
1252 | screen.flags &= ~Screen_WrapNext; |
1248 | screen.flags &= ~Screen_WrapNext; |
1253 | |
1249 | |
1254 | if ((screen.cur.row == screen.bscroll && direction == UP) |
1250 | if ((screen.cur.row == screen.bscroll && direction == UP) |
1255 | || (screen.cur.row == screen.tscroll && direction == DN)) |
1251 | || (screen.cur.row == screen.tscroll && direction == DN)) |
1256 | scr_scroll_text (screen.tscroll, screen.bscroll, dirn); |
1252 | scr_scroll_text (screen.tscroll, screen.bscroll, direction); |
1257 | else |
1253 | else |
1258 | screen.cur.row += dirn; |
1254 | screen.cur.row += direction; |
1259 | |
1255 | |
1260 | clamp_it (screen.cur.row, 0, nrow - 1); |
1256 | clamp_it (screen.cur.row, 0, nrow - 1); |
1261 | selection_check (0); |
1257 | selection_check (0); |
1262 | } |
1258 | } |
1263 | |
1259 | |