binutils-gdb/gdb/tui
Hannes Domani 427cc3b541 Fix using Page-Up in TUI source window close to the top
Currently, when you're already less than a page from the top in the TUI
source window, and you press Page-Up, nothing happens, while I would
expect that it then scrolls the source up to the first line.

It's happening because scrolling a full page up would result in a
negative starting line number, which is then checked if it's higher than
the (unsigned) number of available lines, and since this will always be
true, the original starting line number is restored.
Afterwards it would check if the line number is too low, but since the
negative value was already gone, it didn't do much.

Fixed by moving the low line number check before the maximum line number
check.

Approved-By: Tom Tromey <tom@tromey.com>
2024-11-11 17:13:45 +01:00
..
ChangeLog-1998-2003
tui-command.c Remove tui_refresh_cmd_win 2024-09-07 14:23:04 -06:00
tui-command.h Remove tui_refresh_cmd_win 2024-09-07 14:23:04 -06:00
tui-data.c gdb/tui: cleanup includes 2024-06-07 22:54:06 -04:00
tui-data.h Remove tui_wrefresh 2024-09-07 14:23:04 -06:00
tui-disasm.c gdb: add program_space parameter to lookup_minimal_symbol 2024-08-12 10:31:09 -04:00
tui-disasm.h gdb/tui: cleanup includes 2024-06-07 22:54:06 -04:00
tui-file.c Remove tui_refresh_cmd_win 2024-09-07 14:23:04 -06:00
tui-file.h Update copyright year range in header of all files managed by GDB 2024-01-12 15:49:57 +00:00
tui-hooks.c gdb: pass program space to get_current_source_symtab_and_line 2024-07-15 14:34:12 -04:00
tui-hooks.h Update copyright year range in header of all files managed by GDB 2024-01-12 15:49:57 +00:00
tui-interp.c gdb/tui: cleanup includes 2024-06-07 22:54:06 -04:00
tui-io.c Remove a call to fflush 2024-06-15 12:16:40 -06:00
tui-io.h Update copyright year range in header of all files managed by GDB 2024-01-12 15:49:57 +00:00
tui-layout.c Rename tui_suppress_output 2024-09-07 14:23:04 -06:00
tui-layout.h gdb/tui: change some macros to functions 2024-06-07 22:52:54 -04:00
tui-location.c gdb/tui: cleanup includes 2024-06-07 22:54:06 -04:00
tui-location.h gdb/tui: cleanup includes 2024-06-07 22:54:06 -04:00
tui-regs.c Rename tui_suppress_output 2024-09-07 14:23:04 -06:00
tui-regs.h Clean up refreshing in TUI register window 2024-09-07 14:23:04 -06:00
tui-source.c Fix using Page-Up in TUI source window close to the top 2024-11-11 17:13:45 +01:00
tui-source.h Add line-number styling 2024-09-30 13:23:35 -06:00
tui-status.c gdb/tui: cleanup includes 2024-06-07 22:54:06 -04:00
tui-status.h gdb/tui: change some macros to functions 2024-06-07 22:52:54 -04:00
tui-win.c Rename tui_suppress_output 2024-09-07 14:23:04 -06:00
tui-win.h Update copyright year range in header of all files managed by GDB 2024-01-12 15:49:57 +00:00
tui-wingeneral.c Remove tui_wrefresh 2024-09-07 14:23:04 -06:00
tui-wingeneral.h Remove tui_wrefresh 2024-09-07 14:23:04 -06:00
tui-winsource.c Rename tui_suppress_output 2024-09-07 14:23:04 -06:00
tui-winsource.h Add line-number styling 2024-09-30 13:23:35 -06:00
tui.c Add gdb.events.tui_enabled 2024-11-01 11:06:47 -06:00
tui.h Remove two unneeded forward declarations 2024-04-27 11:30:56 -06:00