diff options
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/panels/bookmarks.c | 1 | ||||
-rw-r--r-- | src/gui/panels/history.c | 19 |
2 files changed, 18 insertions, 2 deletions
diff --git a/src/gui/panels/bookmarks.c b/src/gui/panels/bookmarks.c index 5b0649c..977cbc9 100644 --- a/src/gui/panels/bookmarks.c +++ b/src/gui/panels/bookmarks.c @@ -530,6 +530,7 @@ static void reload_bookmarks_into_treeview(GBookmarksPanel *panel, GLoadedBinary for (b = g_list_first(items); b != NULL; b = g_list_next(b)) { bookmark = G_DB_BOOKMARK(b->data); + if (!g_db_item_is_active(G_DB_ITEM(bookmark))) continue; addr = g_db_bookmark_get_address(bookmark); diff --git a/src/gui/panels/history.c b/src/gui/panels/history.c index 7d0cdd5..74945c7 100644 --- a/src/gui/panels/history.c +++ b/src/gui/panels/history.c @@ -450,11 +450,13 @@ static void change_history_panel_current_binary(GHistoryPanel *panel, GLoadedBin static void on_history_changed(GDbCollection *collec, DBAction action, GDbItem *item, GHistoryPanel *panel) { GtkTreeModel *model; /* Modèle de gestion courant */ - GtkTreeIter iter; /* Boucle de parcours */ GtkTreeSelection *selection; /* Nouvelle sélection à établir*/ + GtkTreeIter iter; /* Boucle de parcours */ model = GTK_TREE_MODEL(panel->store); + selection = gtk_tree_view_get_selection(panel->treeview); + /* Mise à jour de la liste affichée */ bool find_changed_item(GtkTreeModel *_model, GDbItem *target, GtkTreeIter *_found) @@ -544,11 +546,14 @@ static void on_history_changed(GDbCollection *collec, DBAction action, GDbItem * gtk_tree_model_foreach(model, (GtkTreeModelForeachFunc)find_last_active, &iter); - selection = gtk_tree_view_get_selection(panel->treeview); gtk_tree_selection_select_iter(selection, &iter); } + /* Actualisation des accès */ + + on_history_selection_change(selection, panel); + } @@ -620,6 +625,16 @@ static void on_history_selection_change(GtkTreeSelection *selection, GHistoryPan } + else + { + button = GTK_WIDGET(g_object_get_data(G_OBJECT(panel), "undo")); + gtk_widget_set_sensitive(button, FALSE); + + button = GTK_WIDGET(g_object_get_data(G_OBJECT(panel), "redo")); + gtk_widget_set_sensitive(button, FALSE); + + } + } |