From fb3184d8ee941e75d61b3d9ce8fcf7028c8877b8 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sat, 26 Oct 2019 16:00:01 -0600 Subject: Remove struct tui_point struct tui_point does not help very much. It is only used for storage, and never passed between functions. I think it makes the code more verbose without any corresponding benefit, so this patch removes it. gdb/ChangeLog 2019-12-11 Tom Tromey * tui/tui-wingeneral.c (tui_gen_win_info::make_window): Update. * tui/tui-win.c (tui_adjust_win_heights, tui_resize_all): Update. * tui/tui-layout.c (tui_gen_win_info::resize): Update. * tui/tui-data.h (struct tui_point): Remove. (struct tui_gen_win_info) : Remove. : New fields. * tui/tui-command.c (tui_cmd_window::resize): Update. Change-Id: I3f77920585b9ea9e2b4b189f3f3ae32d4da0c252 --- gdb/tui/tui-command.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gdb/tui/tui-command.c') diff --git a/gdb/tui/tui-command.c b/gdb/tui/tui-command.c index 9a432971339..e4c3a1b7491 100644 --- a/gdb/tui/tui-command.c +++ b/gdb/tui/tui-command.c @@ -50,8 +50,8 @@ tui_cmd_window::resize (int height_, int width_, int origin_x, int origin_y) } else viewport_height = 1; - origin.x = origin_x; - origin.y = origin_y; + x = origin_x; + y = origin_y; if (handle == nullptr) make_window (); @@ -66,7 +66,7 @@ tui_cmd_window::resize (int height_, int width_, int origin_x, int origin_y) #ifdef HAVE_WRESIZE wresize (handle.get (), height, width); #endif - mvwin (handle.get (), origin.y, origin.x); + mvwin (handle.get (), y, x); wmove (handle.get (), 0, 0); } } -- cgit v1.2.1