+2019-07-17 Tom Tromey <tom@tromey.com>
+
+ * tui/tui-winsource.c (tui_clear_source_content)
+ (tui_show_source_content): Update.
+ * tui/tui-source.c (tui_source_window::showing_source_p): Check
+ whether content is empty.
+ * tui/tui-data.h (struct tui_source_window_base) <content_in_use>:
+ Remove.
+
2019-07-17 Tom Tromey <tom@tromey.com>
* tui/tui-winsource.c (tui_erase_source_content): Clear the
LINE_NO in this source window; false otherwise. */
virtual bool location_matches_p (struct bp_location *loc, int line_no) = 0;
- /* Can it be used, or is it already used? */
- bool content_in_use = false;
/* Does the locator belong to this window? */
bool m_has_locator = false;
/* Execution information window. */
bool
tui_source_window::showing_source_p (const char *fullname) const
{
- return (content_in_use
+ return (!content.empty ()
&& (filename_cmp (tui_locator_win_info_ptr ()->full_name,
fullname) == 0));
}
{
int i;
- win_info->content_in_use = false;
tui_erase_source_content (win_info);
for (i = 0; i < win_info->content.size (); i++)
{
tui_check_and_display_highlight_if_needed (win_info);
win_info->refresh_window ();
- win_info->content_in_use = true;
}
/* See tui-data.h. */