aboutsummaryrefslogtreecommitdiff
path: root/gdb/tui/tui-win.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-07-05 17:14:46 -0600
committerTom Tromey <tom@tromey.com>2019-08-13 14:52:09 -0600
commitb4ef5aeb3a1880490f9441655d9de74727c9063a (patch)
tree991ca037ba947b6b55c5ae26f2b654df62e839b6 /gdb/tui/tui-win.c
parentfede52738f3ed3e375d84197380ae1a6cd35c6fe (diff)
downloadgdb-b4ef5aeb3a1880490f9441655d9de74727c9063a.zip
gdb-b4ef5aeb3a1880490f9441655d9de74727c9063a.tar.gz
gdb-b4ef5aeb3a1880490f9441655d9de74727c9063a.tar.bz2
Change tui_check_and_display_highlight_if_needed to be a method
This changes tui_check_and_display_highlight_if_needed to be a method on tui_win_info. This makes it clear that the NULL check in that function is not needed, so it is removed here. gdb/ChangeLog 2019-08-13 Tom Tromey <tom@tromey.com> * tui/tui-winsource.c (tui_erase_source_content) (tui_show_source_content, tui_source_window_base::refresh_all): Update. * tui/tui-wingeneral.h (tui_check_and_display_highlight_if_needed): Don't declare. * tui/tui-wingeneral.c (tui_win_info::check_and_display_highlight_if_needed): Rename from check_and_display_highlight_if_needed. * tui/tui-win.c (tui_rehighlight_all) (tui_win_info::make_visible_with_new_height): Update. * tui/tui-regs.c (tui_data_window::display_registers_from_line) (tui_data_window::erase_data_content) (tui_data_window::display_all_data): Update. * tui/tui-data.h (struct tui_win_info) <check_and_display_highlight_if_needed>: Declare.
Diffstat (limited to 'gdb/tui/tui-win.c')
-rw-r--r--gdb/tui/tui-win.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/tui/tui-win.c b/gdb/tui/tui-win.c
index be01c15..ff4f2ee 100644
--- a/gdb/tui/tui-win.c
+++ b/gdb/tui/tui-win.c
@@ -515,7 +515,7 @@ void
tui_rehighlight_all (void)
{
for (tui_win_info *win_info : all_tui_windows ())
- tui_check_and_display_highlight_if_needed (win_info);
+ win_info->check_and_display_highlight_if_needed ();
}
/* Resize all the windows based on the terminal size. This function
@@ -1205,7 +1205,7 @@ void
tui_win_info::make_visible_with_new_height ()
{
make_visible (true);
- tui_check_and_display_highlight_if_needed (this);
+ check_and_display_highlight_if_needed ();
do_make_visible_with_new_height ();
}