Reimplement TUI "C-x 1" binding
The TUI "C-x 1" key binding removes TUI windows, based on the current
layout. With user-defined layouts, this is no longer easy to do.
This patch changes "C-x 1" to simply delete windows, leaving just the
focus window, the locator, and the command window.
gdb/ChangeLog
2020-02-22 Tom Tromey <tom@tromey.com>
* tui/tui.c (tui_rl_delete_other_windows): Call
tui_remove_some_windows.
* tui/tui-layout.h (class tui_layout_base) <remove_windows>:
Declare method.
(class tui_layout_window) <remove_windows>: New method.
(class tui_layout_split) <remove_windows>: Declare.
(tui_remove_some_windows): Declare.
* tui/tui-layout.c (tui_remove_some_windows): New function.
(tui_layout_split::remove_windows): New method.
Change-Id: If186f9c3f263913e963b965204481d1b4385c6d4