+2019-12-20 Tom Tromey <tom@tromey.com>
+
+ * tui/tui-winsource.c (tui_update_source_windows_with_addr)
+ (tui_update_source_windows_with_line): Call update_source_window.
+ * tui/tui-source.h (struct tui_source_window)
+ <show_symtab_source>: Don't declare.
+ * tui/tui-source.c (tui_source_window::show_symtab_source):
+ Remove.
+
2019-12-20 Tom Tromey <tom@tromey.com>
* tui/tui-winsource.c (tui_update_source_windows_with_addr): Call
}
-/* Function to display source in the source window. This function
- initializes the horizontal scroll to 0. */
-void
-tui_source_window::show_symtab_source (struct gdbarch *gdbarch,
- struct symtab *s,
- struct tui_line_or_address line)
-{
- horizontal_offset = 0;
- update_source_window_as_is (gdbarch, s, line);
-}
-
-
/* Answer whether the source is currently displayed in the source
window. */
bool
do_erase_source_content (_("[ No Source Available ]"));
}
- void show_symtab_source (struct gdbarch *, struct symtab *,
- struct tui_line_or_address);
-
protected:
void do_scroll_vertical (int num_to_scroll) override;
{
l.loa = LOA_LINE;
l.u.line_no = sal.line;
- TUI_SRC_WIN->show_symtab_source (gdbarch, sal.symtab, l);
+ TUI_SRC_WIN->update_source_window (gdbarch, sal.symtab, l);
}
}
else
default:
l.loa = LOA_LINE;
l.u.line_no = line;
- TUI_SRC_WIN->show_symtab_source (gdbarch, s, l);
+ TUI_SRC_WIN->update_source_window (gdbarch, s, l);
if (tui_current_layout () == SRC_DISASSEM_COMMAND)
{
find_line_pc (s, line, &pc);