[pushed] Move can_box to tui_gen_win_info
Sourceware to Gerrit sync (Code Review)
gerrit@gnutoolchain-gerrit.osci.io
Wed Dec 11 23:21:00 GMT 2019
Sourceware to Gerrit sync has submitted this change.
Change URL: https://gnutoolchain-gerrit.osci.io/r/c/binutils-gdb/+/512
......................................................................
Move can_box to tui_gen_win_info
This moves the can_box method to tui_gen_win_info, so that it will be
available on the tui_locator_window class. This will be used in a
subsequent patch.
gdb/ChangeLog
2019-12-11 Tom Tromey <tom@tromey.com>
* tui/tui-data.h (struct tui_gen_win_info) <can_box>: New method.
(struct tui_win_info) <can_box>: Update.
Change-Id: Idfa58af41341607932d3c39415f6a35ee9b5d3dc
---
M gdb/ChangeLog
M gdb/tui/tui-data.h
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 20d3321..88fa1c1 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,10 @@
2019-12-11 Tom Tromey <tom@tromey.com>
+ * tui/tui-data.h (struct tui_gen_win_info) <can_box>: New method.
+ (struct tui_win_info) <can_box>: Update.
+
+2019-12-11 Tom Tromey <tom@tromey.com>
+
* tui/tui-stack.h (struct tui_locator_window) <max_height>: New
method.
* tui/tui-regs.h (struct tui_data_item_window) <max_height>: New
diff --git a/gdb/tui/tui-data.h b/gdb/tui/tui-data.h
index d3b84b1..d441a38 100644
--- a/gdb/tui/tui-data.h
+++ b/gdb/tui/tui-data.h
@@ -85,6 +85,12 @@
/* Compute the maximum height of this window. */
virtual int max_height () const = 0;
+ /* Return true if this window can be boxed. */
+ virtual bool can_box () const
+ {
+ return false;
+ }
+
/* Resize this window. The parameters are used to set the window's
size and position. */
virtual void resize (int height, int width,
@@ -203,7 +209,7 @@
return true;
}
- virtual bool can_box () const
+ bool can_box () const override
{
return true;
}
--
Gerrit-Project: binutils-gdb
Gerrit-Branch: master
Gerrit-Change-Id: Idfa58af41341607932d3c39415f6a35ee9b5d3dc
Gerrit-Change-Number: 512
Gerrit-PatchSet: 4
Gerrit-Owner: Tom Tromey <tromey@sourceware.org>
Gerrit-Reviewer: Andrew Burgess <andrew.burgess@embecosm.com>
Gerrit-MessageType: merged
More information about the Gdb-patches
mailing list