Patchwork [19/19] Remove tui_gen_win_info::last_visible_line

login
register
mail settings
Submitter Tom Tromey
Date Aug. 3, 2019, 1:29 p.m.
Message ID <20190803132925.25074-20-tom@tromey.com>
Download mbox | patch
Permalink /patch/33945/
State New
Headers show

Comments

Tom Tromey - Aug. 3, 2019, 1:29 p.m.
The last_visible_line field of tui_gen_win_info is not used, so remove
it.

gdb/ChangeLog
2019-08-03  Tom Tromey  <tom@tromey.com>

	* tui/tui-data.h (struct tui_gen_win_info) <last_visible_line>:
	Remove.
	* tui/tui-data.c (tui_initialize_static_data): Update.
---
 gdb/ChangeLog      | 6 ++++++
 gdb/tui/tui-data.c | 3 +--
 gdb/tui/tui-data.h | 2 --
 3 files changed, 7 insertions(+), 4 deletions(-)

Patch

diff --git a/gdb/tui/tui-data.c b/gdb/tui/tui-data.c
index bb725c199cc..add1f33926f 100644
--- a/gdb/tui/tui-data.c
+++ b/gdb/tui/tui-data.c
@@ -262,8 +262,7 @@  tui_initialize_static_data ()
     win->height =
     win->origin.x =
     win->origin.y =
-    win->viewport_height =
-    win->last_visible_line = 0;
+    win->viewport_height = 0;
   win->handle = NULL;
   win->is_visible = false;
   win->title = 0;
diff --git a/gdb/tui/tui-data.h b/gdb/tui/tui-data.h
index 08178e49ea8..3493b5ed68b 100644
--- a/gdb/tui/tui-data.h
+++ b/gdb/tui/tui-data.h
@@ -79,8 +79,6 @@  public:
   struct tui_point origin = {0, 0};
   /* Viewport height.  */
   int viewport_height = 0;
-  /* Index of last visible line.  */
-  int last_visible_line = 0;
   /* Whether the window is visible or not.  */
   bool is_visible = false;
   /* Window title to display.  */