aboutsummaryrefslogtreecommitdiff
path: root/gdb/tui/tui-disasm.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2019-07-11 18:24:07 -0600
committerTom Tromey <tom@tromey.com>2019-08-16 11:28:34 -0600
commit017f982820d408fb49657b9b9b8f45a9616c5f21 (patch)
treecf0b93bc9dc5475957c04db28ca22ff9b3c82700 /gdb/tui/tui-disasm.c
parented8358e9491d5ae0a8ee021c162a85867af1146a (diff)
downloadgdb-017f982820d408fb49657b9b9b8f45a9616c5f21.zip
gdb-017f982820d408fb49657b9b9b8f45a9616c5f21.tar.gz
gdb-017f982820d408fb49657b9b9b8f45a9616c5f21.tar.bz2
Change tui_update_source_window to be a method
This changes tui_update_source_window to be a method on tui_source_window_base. gdb/ChangeLog 2019-08-16 Tom Tromey <tom@tromey.com> * tui/tui-winsource.h (struct tui_source_window_base) <update_source_window>: Declare. (tui_update_source_window): Don't declare. * tui/tui-winsource.c (tui_source_window_base::update_source_window): Rename from tui_update_source_window. (tui_source_window_base::rerender): Update. * tui/tui-source.c (tui_source_window::maybe_update): Update. * tui/tui-disasm.c (tui_show_disassem) (tui_show_disassem_and_update_source) (tui_disasm_window::maybe_update): Update.
Diffstat (limited to 'gdb/tui/tui-disasm.c')
-rw-r--r--gdb/tui/tui-disasm.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/gdb/tui/tui-disasm.c b/gdb/tui/tui-disasm.c
index d47639c..221e48e 100644
--- a/gdb/tui/tui-disasm.c
+++ b/gdb/tui/tui-disasm.c
@@ -257,7 +257,7 @@ tui_show_disassem (struct gdbarch *gdbarch, CORE_ADDR start_addr)
val.loa = LOA_ADDRESS;
val.u.addr = start_addr;
- tui_update_source_window (TUI_DISASM_WIN, gdbarch, s, val);
+ TUI_DISASM_WIN->update_source_window (gdbarch, s, val);
/* If the focus was in the src win, put it in the asm win, if the
source view isn't split. */
@@ -285,7 +285,7 @@ tui_show_disassem_and_update_source (struct gdbarch *gdbarch,
sal = find_pc_line (start_addr, 0);
val.loa = LOA_LINE;
val.u.line_no = sal.line;
- tui_update_source_window (TUI_SRC_WIN, gdbarch, sal.symtab, val);
+ TUI_SRC_WIN->update_source_window (gdbarch, sal.symtab, val);
if (sal.symtab)
{
set_current_source_symtab_and_line (sal);
@@ -418,8 +418,7 @@ tui_disasm_window::maybe_update (struct frame_info *fi, symtab_and_line sal,
a.loa = LOA_ADDRESS;
a.u.addr = low;
if (!addr_is_displayed (addr))
- tui_update_source_window (this, get_frame_arch (fi),
- sal.symtab, a);
+ update_source_window (get_frame_arch (fi), sal.symtab, a);
else
{
a.u.addr = addr;