summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--src/editor.c5
2 files changed, 9 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index fadf8f6..a21bd1c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
09-08-30 Cyrille Bagard <nocbos@gmail.com>
+ * src/editor.c:
+ Quickly fix a bug in binary view lookup.
+
+09-08-30 Cyrille Bagard <nocbos@gmail.com>
+
* configure.ac:
Enable AM_SILENT_RULES and disable GTK_DISABLE_DEPRECATED.
diff --git a/src/editor.c b/src/editor.c
index 3830e4c..c026426 100644
--- a/src/editor.c
+++ b/src/editor.c
@@ -761,6 +761,7 @@ void mcb_view_change_support(GtkRadioMenuItem *menuitem, GObject *ref)
GtkBinView *binview; /* Afficheur effectif de code */
GtkWidget *panel; /* Nouveau support à utiliser */
GtkDockPanel *dpanel; /* Support de panneaux */
+ char *title; /* Titre associé au binaire */
GtkDockItem *ditem; /* Panneau avec ses infos. */
/* On ne traite qu'une seule fois ! */
@@ -780,7 +781,9 @@ void mcb_view_change_support(GtkRadioMenuItem *menuitem, GObject *ref)
g_object_set_data(ref, "binview", binview);
dpanel = GTK_DOCK_PANEL(g_object_get_data(ref, "binpanel"));
- ditem = gtk_dock_panel_item_from_name(dpanel, g_openida_binary_to_string(binary));
+
+ title = g_openida_binary_to_string(binary);
+ ditem = gtk_dock_panel_item_from_name(dpanel, strrchr(title, '/') + 1);
gtk_dock_panel_replace_item_content(dpanel, ditem, panel);