From eded5828fa91ffa5aeb7d17ffa8102e9859f1094 Mon Sep 17 00:00:00 2001 From: luxick Date: Wed, 28 Feb 2018 11:24:33 +0100 Subject: [PATCH] Add accelerators to menu items. --- dsst/dsst_gtk3/handlers/death_handlers.py | 2 ++ dsst/dsst_gtk3/resources/glade/window.glade | 3 +++ 2 files changed, 5 insertions(+) diff --git a/dsst/dsst_gtk3/handlers/death_handlers.py b/dsst/dsst_gtk3/handlers/death_handlers.py index b4c4da4..12e73a7 100644 --- a/dsst/dsst_gtk3/handlers/death_handlers.py +++ b/dsst/dsst_gtk3/handlers/death_handlers.py @@ -9,6 +9,8 @@ class DeathHandlers: def do_add_death(self, *_): ep_id = self.app.get_selected_episode_id() + if not ep_id: + return result = dialogs.show_edit_death_dialog(self.app.ui, ep_id) if result == Gtk.ResponseType.OK: self.app.reload_for_season() diff --git a/dsst/dsst_gtk3/resources/glade/window.glade b/dsst/dsst_gtk3/resources/glade/window.glade index 31589aa..3d00e28 100644 --- a/dsst/dsst_gtk3/resources/glade/window.glade +++ b/dsst/dsst_gtk3/resources/glade/window.glade @@ -1234,6 +1234,7 @@ True + False False Manage Seasons True @@ -1260,6 +1261,7 @@ Add Death True + @@ -1268,6 +1270,7 @@ False Add Victory True +