diff options
Diffstat (limited to 'src/gui/panels/bookmarks.c')
-rw-r--r-- | src/gui/panels/bookmarks.c | 35 |
1 files changed, 33 insertions, 2 deletions
diff --git a/src/gui/panels/bookmarks.c b/src/gui/panels/bookmarks.c index fd8af25..3c1e719 100644 --- a/src/gui/panels/bookmarks.c +++ b/src/gui/panels/bookmarks.c @@ -46,6 +46,7 @@ #include "../../glibext/chrysamarshal.h" #include "../../glibext/signal.h" #include "../../gtkext/easygtk.h" +#include "../../gtkext/gtkdisplaypanel.h" #include "../../gtkext/gtkdockable-int.h" @@ -106,6 +107,8 @@ static void g_bookmarks_panel_dispose(GBookmarksPanel *); /* Procède à la libération totale de la mémoire. */ static void g_bookmarks_panel_finalize(GBookmarksPanel *); +/* Réagit à un changement d'affichage principal de contenu. */ +static void change_bookmarks_panel_current_content(GBookmarksPanel *, GLoadedContent *, GLoadedContent *); /* ------------------------- AFFICHAGE A L'AIDE D'UNE LISTE ------------------------- */ @@ -208,7 +211,7 @@ static void g_bookmarks_panel_class_init(GBookmarksPanelClass *klass) editem = G_EDITOR_ITEM_CLASS(klass); - editem->update_binary = (update_item_binary_fc)reload_bookmarks_into_treeview; + editem->change_content = (change_item_content_fc)change_bookmarks_panel_current_content; panel = G_PANEL_ITEM_CLASS(klass); @@ -426,6 +429,34 @@ GPanelItem *g_bookmarks_panel_new(void) } +/****************************************************************************** +* * +* Paramètres : panel = panneau à mettre à jour. * +* old = ancien contenu chargé analysé. * +* new = nouveau contenu chargé à analyser. * +* * +* Description : Réagit à un changement d'affichage principal de contenu. * +* * +* Retour : - * +* * +* Remarques : - * +* * +******************************************************************************/ + +static void change_bookmarks_panel_current_content(GBookmarksPanel *panel, GLoadedContent *old, GLoadedContent *new) +{ + GLoadedBinary *binary; /* Autre version de l'instance */ + + if (G_IS_LOADED_BINARY(new)) + binary = G_LOADED_BINARY(new); + else + binary = NULL; + + reload_bookmarks_into_treeview(panel, binary); + +} + + /* ---------------------------------------------------------------------------------- */ /* AFFICHAGE A L'AIDE D'UNE LISTE */ @@ -955,7 +986,7 @@ static void on_param_value_edited(GtkCellRendererText *renderer, gchar *path, gc static void update_filtered_bookmarks(GBookmarksPanel *panel) { - //reload_bookmarks_into_treeview(panel, panel->binary); + reload_bookmarks_into_treeview(panel, panel->binary); } |