diff options
author | Tom Tromey <tom@tromey.com> | 2019-12-30 09:07:33 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2019-12-30 09:07:33 -0700 |
commit | 87d557ae1b944a21c86e3148daadeb4469b8cda9 (patch) | |
tree | 7826816491a02cdcd44992e18a0c279d9355d8c9 /gdb/tui/tui-win.c | |
parent | a7ac9aa525de25d3bc6e7bfd37615092a4f94055 (diff) | |
download | binutils-gdb-87d557ae1b944a21c86e3148daadeb4469b8cda9.tar.gz |
Use "bool" in more spots in TUI
This changes a few spots in the TUI to use "bool" rather than "int".
Tested on x86-64 Fedora 28.
gdb/ChangeLog
2019-12-30 Tom Tromey <tom@tromey.com>
* tui/tui-interp.c (tui_start_enabled): Now bool.
(_initialize_tui_interp): Update.
* tui/tui-hooks.c (tui_refreshing_registers): Now bool.
(tui_register_changed)
(tui_refresh_frame_and_register_information): Update.
* tui/tui-win.c (tui_update_variables): Return bool.
* tui/tui-win.h (tui_update_variables): Return bool.
* tui/tui.c (tui_get_command_dimension): Return bool.
* tui/tui.h (tui_get_command_dimension): Return bool.
Change-Id: I55b7f2d62d2ef88da3587dc914ada9f463ad8d2b
Diffstat (limited to 'gdb/tui/tui-win.c')
-rw-r--r-- | gdb/tui/tui-win.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gdb/tui/tui-win.c b/gdb/tui/tui-win.c index ac3690a7f45..959b0cdd76f 100644 --- a/gdb/tui/tui-win.c +++ b/gdb/tui/tui-win.c @@ -254,23 +254,23 @@ translate (const char *name, struct tui_translate *table) /* Update the tui internal configuration according to gdb settings. Returns 1 if the configuration has changed and the screen should be redrawn. */ -int -tui_update_variables (void) +bool +tui_update_variables () { - int need_redraw = 0; + bool need_redraw = false; struct tui_translate *entry; entry = translate (tui_border_mode, tui_border_mode_translate); if (tui_border_attrs != entry->value) { tui_border_attrs = entry->value; - need_redraw = 1; + need_redraw = true; } entry = translate (tui_active_border_mode, tui_border_mode_translate); if (tui_active_border_attrs != entry->value) { tui_active_border_attrs = entry->value; - need_redraw = 1; + need_redraw = true; } /* If one corner changes, all characters are changed. @@ -280,7 +280,7 @@ tui_update_variables (void) if (tui_border_lrcorner != (chtype) entry->value) { tui_border_lrcorner = (entry->value < 0) ? ACS_LRCORNER : entry->value; - need_redraw = 1; + need_redraw = true; } entry = translate (tui_border_kind, tui_border_kind_translate_llcorner); tui_border_llcorner = (entry->value < 0) ? ACS_LLCORNER : entry->value; |