diff options
Diffstat (limited to 'src/application.rs')
-rw-r--r-- | src/application.rs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/application.rs b/src/application.rs index 6c51523..f8b5527 100644 --- a/src/application.rs +++ b/src/application.rs @@ -20,7 +20,7 @@ use gtk::subclass::prelude::*; use gtk::{gdk, gio, glib}; use crate::config; -use crate::ui::FurtheranceWindow; +use crate::ui::{FurtheranceWindow, FurPreferencesWindow}; use crate::database; mod imp { @@ -96,6 +96,13 @@ impl FurtheranceApplication { })); self.add_action(&quit_action); + let preferences_action = gio::SimpleAction::new("preferences", None); + preferences_action.connect_activate(clone!(@weak self as app => move |_, _| { + FurPreferencesWindow::new().show(); + })); + self.set_accels_for_action("app.preferences", &["<primary>comma"]); + self.add_action(&preferences_action); + let about_action = gio::SimpleAction::new("about", None); about_action.connect_activate(clone!(@weak self as app => move |_, _| { app.show_about(); |