diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2018-07-16 20:11:21 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2018-07-16 20:11:21 (GMT) |
commit | f6e56cebfa878dd32a2405fd0c916a40140a1ff0 (patch) | |
tree | 3e364d2e2b2de19b85ab6d14f856d4b8db11737a /src/gui/panels/history.c | |
parent | e0d03e3eddb9d240cc21ac1b7a7ade915fd17942 (diff) |
Applied a new GUI update with the new loaded panels features.
Diffstat (limited to 'src/gui/panels/history.c')
-rw-r--r-- | src/gui/panels/history.c | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/src/gui/panels/history.c b/src/gui/panels/history.c index c43534b..50e72da 100644 --- a/src/gui/panels/history.c +++ b/src/gui/panels/history.c @@ -33,7 +33,7 @@ #include "panel-int.h" -#include "../../analysis/db/collection.h" +#include "../../analysis/binary.h" #include "../../glibext/chrysamarshal.h" #include "../../glibext/signal.h" #include "../../gtkext/easygtk.h" @@ -87,7 +87,7 @@ static void g_history_panel_dispose(GHistoryPanel *); static void g_history_panel_finalize(GHistoryPanel *); /* Réagit à un changement d'affichage principal de contenu. */ -static void change_history_panel_current_binary(GHistoryPanel *, GLoadedBinary *); +static void change_history_panel_current_content(GHistoryPanel *, GLoadedContent *, GLoadedContent *); /* Réagit à une modification au sein d'une collection donnée. */ static void on_history_changed(GDbCollection *, DBAction, GDbItem *, GHistoryPanel *); @@ -137,7 +137,7 @@ static void g_history_panel_class_init(GHistoryPanelClass *klass) editem = G_EDITOR_ITEM_CLASS(klass); - editem->update_binary = (update_item_binary_fc)change_history_panel_current_binary; + editem->change_content = (change_item_content_fc)change_history_panel_current_content; } @@ -326,8 +326,9 @@ GPanelItem *g_history_panel_new(void) /****************************************************************************** * * -* Paramètres : panel = panneau à mettre à jour. * -* binary = nouvelle instance de binaire analysé. * +* 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. * * * @@ -337,8 +338,9 @@ GPanelItem *g_history_panel_new(void) * * ******************************************************************************/ -static void change_history_panel_current_binary(GHistoryPanel *panel, GLoadedBinary *binary) +static void change_history_panel_current_content(GHistoryPanel *panel, GLoadedContent *old, GLoadedContent *new) { + GLoadedBinary *binary; /* Autre version de l'instance */ GList *collections; /* Ensemble de collections */ GList *c; /* Boucle de parcours #1 */ GDbCollection *collec; /* Collection visée manipulée */ @@ -348,6 +350,11 @@ static void change_history_panel_current_binary(GHistoryPanel *panel, GLoadedBin GDbItem *item; /* Elément à intégrer */ GtkTreeIter iter; /* Point d'insertion */ + if (G_IS_LOADED_BINARY(new)) + binary = G_LOADED_BINARY(new); + else + binary = NULL; + /* Basculement du binaire utilisé */ if (panel->binary != NULL) |