Don't derive tui_data_item_window from tui_gen_win_info
authorTom Tromey <tom@tromey.com>
Thu, 2 Jul 2020 03:21:12 +0000 (21:21 -0600)
committerTom Tromey <tom@tromey.com>
Thu, 2 Jul 2020 03:21:15 +0000 (21:21 -0600)
commit7134f2eb9230f86adb8839ac9cc737c7f4b47b59
tree5beb2778dee4f284d05d5a6988b96e745031ecf2
parent22b7b0412bceb80ecd5de39a8e05742eb3cbb324
Don't derive tui_data_item_window from tui_gen_win_info

There's no deep reason that tui_data_item_window should derive from
tui_gen_win_info -- it currently uses a curses window to render, but
that isn't truly needed, and it adds some hacks to other parts of the
TUI.

This patch changes tui_data_item_window so that it doesn't have a base
class, and updates the register window.  This simplifies the code and
enables a subsequent cleanup.

gdb/ChangeLog
2020-07-01  Tom Tromey  <tom@tromey.com>

* tui/tui-regs.c (tui_data_window::display_registers_from)
(tui_data_window::display_registers_from)
(tui_data_window::first_data_item_displayed)
(tui_data_window::delete_data_content_windows): Update.
(tui_data_window::refresh_window, tui_data_window::no_refresh):
Remove.
(tui_data_window::check_register_values): Update.
(tui_data_item_window::rerender): Add parameters.  Update.
(tui_data_item_window::refresh_window): Remove.
* tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
virtual.
* tui/tui-regs.h (struct tui_data_item_window): Don't derive from
tui_gen_win_info.
<refresh_window, max_height, min_height>: Remove.
<rerender>: Add parameters.
<x, y, visible>: New members.
(struct tui_data_window) <refresh_window, no_refresh>: Remove.
<m_item_width>: New member.
gdb/ChangeLog
gdb/tui/tui-data.h
gdb/tui/tui-regs.c
gdb/tui/tui-regs.h
This page took 0.033312 seconds and 4 git commands to generate.