summaryrefslogtreecommitdiff
path: root/src/searches/SavedSearchPage.vala
diff options
context:
space:
mode:
Diffstat (limited to 'src/searches/SavedSearchPage.vala')
-rw-r--r--src/searches/SavedSearchPage.vala16
1 files changed, 12 insertions, 4 deletions
diff --git a/src/searches/SavedSearchPage.vala b/src/searches/SavedSearchPage.vala
index c57ec7d..9267137 100644
--- a/src/searches/SavedSearchPage.vala
+++ b/src/searches/SavedSearchPage.vala
@@ -53,12 +53,20 @@ public class SavedSearchPage : CollectionPage {
{ "DeleteSearch", on_delete_search }
};
- protected override void add_actions () {
- base.add_actions ();
+ protected override void add_actions(GLib.ActionMap map) {
+ base.add_actions(map);
- AppWindow.get_instance ().add_action_entries (entries, this);
+ map.add_action_entries(entries, this);
}
-
+
+ protected override void remove_actions(GLib.ActionMap map) {
+ base.remove_actions(map);
+ foreach (var entry in entries) {
+ map.remove_action(entry.name);
+ }
+ }
+
+
private void on_delete_search() {
if (Dialogs.confirm_delete_saved_search(search))
AppWindow.get_command_manager().execute(new DeleteSavedSearchCommand(search));