summaryrefslogtreecommitdiff
path: root/gdb/tui/tui-layout.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-07-06 08:21:38 -0600
committerTom Tromey <tom@tromey.com>2019-08-15 12:29:28 -0600
commit65962b20b6df7e8961ec4002179dbd51a33a627f (patch)
treefe58f823af4202c3533085c1619c5a3267c82d89 /gdb/tui/tui-layout.c
parent22a2ab04f58dc7c3f5fb0e6d8f0fa96ee4aa3951 (diff)
downloadbinutils-gdb-65962b20b6df7e8961ec4002179dbd51a33a627f.tar.gz
Simplify TUI boxing
In the TUI, whether or not a window can be boxed is a property of the window's type. This adds a can_box method to the window classes, and changes tui_make_window to defer to this, removing the "box_it" paramter. This also lets us remove "enum tui_box", as it is no longer used. gdb/ChangeLog 2019-08-15 Tom Tromey <tom@tromey.com> * tui/tui-wingeneral.h (tui_make_window): Update. * tui/tui-wingeneral.c (tui_make_window): Remove "box_it" parameter. (tui_gen_win_info::make_visible): Update. * tui/tui-regs.c (tui_data_window::display_registers_from): Update. * tui/tui-layout.c (show_source_disasm_command) (show_source_or_disasm_and_command): Update. * tui/tui-data.h (struct tui_gen_win_info) <can_box>: New method. (enum tui_box): Remove. (struct tui_win_info) <can_box>: New method. * tui/tui-command.h (struct tui_cmd_window) <can_box>: New method.
Diffstat (limited to 'gdb/tui/tui-layout.c')
-rw-r--r--gdb/tui/tui-layout.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/tui/tui-layout.c b/gdb/tui/tui-layout.c
index 3683835954d..69b929d37b2 100644
--- a/gdb/tui/tui-layout.c
+++ b/gdb/tui/tui-layout.c
@@ -546,7 +546,7 @@ show_source_disasm_command (void)
tui_term_height () - cmd_height);
/* FIXME tui_cmd_window won't recreate the handle on
make_visible, so we need this instead. */
- tui_make_window (TUI_CMD_WIN, DONT_BOX_WINDOW);
+ tui_make_window (TUI_CMD_WIN);
current_layout = SRC_DISASSEM_COMMAND;
}
@@ -674,6 +674,6 @@ show_source_or_disasm_and_command (enum tui_layout_type layout_type)
src_height);
/* FIXME tui_cmd_window won't recreate the handle on
make_visible, so we need this instead. */
- tui_make_window (TUI_CMD_WIN, DONT_BOX_WINDOW);
+ tui_make_window (TUI_CMD_WIN);
current_layout = layout_type;
}