doc/ChangeLog:
[deliverable/binutils-gdb.git] / gdb / tui / tui-hooks.c
index 4defb284e6475f2cf23262c44c81a908a0f94ea4..7114b01a6e24a34e020a8c9d54a68830d18244a7 100644 (file)
@@ -36,6 +36,7 @@
 #include "gdb-events.h"
 #include "ui-out.h"
 #include "top.h"
+#include "observer.h"
 #include <unistd.h>
 #include <fcntl.h>
 
 
 int tui_target_has_run = 0;
 
-static void (* tui_target_new_objfile_chain) (struct objfile*);
-
 static void
 tui_new_objfile_hook (struct objfile* objfile)
 {
   if (tui_active)
     tui_display_main ();
-  
-  if (tui_target_new_objfile_chain)
-    tui_target_new_objfile_chain (objfile);
 }
 
 static int ATTR_FORMAT (printf, 1, 0)
@@ -302,6 +298,5 @@ void
 _initialize_tui_hooks (void)
 {
   /* Install the permanent hooks.  */
-  tui_target_new_objfile_chain = deprecated_target_new_objfile_hook;
-  deprecated_target_new_objfile_hook = tui_new_objfile_hook;
+  observer_attach_new_objfile (tui_new_objfile_hook);
 }
This page took 0.024497 seconds and 4 git commands to generate.