diff options
author | Stephane Carrez <stcarrez@nerim.fr> | 2002-09-01 12:49:32 +0000 |
---|---|---|
committer | Stephane Carrez <stcarrez@nerim.fr> | 2002-09-01 12:49:32 +0000 |
commit | 1df91d8b37d70642a6751911c8721cb54d92a16c (patch) | |
tree | f5d1c3f87574b11afcd94a156f89e9f92f1aaf19 /gdb/tui | |
parent | 09f138080ce7e614bbd80a65b3a493bb6fdb0b29 (diff) | |
download | gdb-1df91d8b37d70642a6751911c8721cb54d92a16c.tar.gz |
* tui-hooks.c (tui_detach_hook): New hook to know when a process dies.
(tui_install_hooks): Install it.
(tui_remove_hooks): Remove it.
Diffstat (limited to 'gdb/tui')
-rw-r--r-- | gdb/tui/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/tui/tui-hooks.c | 11 |
2 files changed, 17 insertions, 0 deletions
diff --git a/gdb/tui/ChangeLog b/gdb/tui/ChangeLog index a29d0021d42..4a190edc518 100644 --- a/gdb/tui/ChangeLog +++ b/gdb/tui/ChangeLog @@ -1,5 +1,11 @@ 2002-09-01 Stephane Carrez <stcarrez@nerim.fr> + * tui-hooks.c (tui_detach_hook): New hook to know when a process dies. + (tui_install_hooks): Install it. + (tui_remove_hooks): Remove it. + +2002-09-01 Stephane Carrez <stcarrez@nerim.fr> + * tuiData.h (FILE_PREFIX): Don't define. (blankStr, locationStr, breakStr): Don't declare. (breakLocationStr, nullStr, historyLimit, setHistoryLimitTo): Likewise. diff --git a/gdb/tui/tui-hooks.c b/gdb/tui/tui-hooks.c index fe144a36590..35d7ce8c3fa 100644 --- a/gdb/tui/tui-hooks.c +++ b/gdb/tui/tui-hooks.c @@ -277,6 +277,15 @@ tui_print_frame_info_listing_hook (struct symtab *s, int line, tuiShowFrameInfo (selected_frame); } +/* Called when the target process died or is detached. + Update the status line. */ +static void +tui_detach_hook (void) +{ + tuiShowFrameInfo (0); + tui_display_main (); +} + /* Install the TUI specific hooks. */ void tui_install_hooks (void) @@ -292,6 +301,7 @@ tui_install_hooks (void) registers_changed_hook = tui_registers_changed_hook; register_changed_hook = tui_register_changed_hook; + detach_hook = tui_detach_hook; } /* Remove the TUI specific hooks. */ @@ -304,6 +314,7 @@ tui_remove_hooks (void) query_hook = 0; registers_changed_hook = 0; register_changed_hook = 0; + detach_hook = 0; /* Restore the previous event hooks. */ set_gdb_event_hooks (tui_old_event_hooks); |