From 4744cfba1b4e4b8dc57d196a4e1019a2903b2ef4 Mon Sep 17 00:00:00 2001 From: teamcons Date: Sun, 21 Sep 2025 21:40:48 +0200 Subject: [PATCH] Add action-quit --- src/Application.vala | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/Application.vala b/src/Application.vala index a24e3c14..c989f546 100644 --- a/src/Application.vala +++ b/src/Application.vala @@ -4,6 +4,13 @@ */ public class Onboarding.App : Gtk.Application { + public const string ACTION_PREFIX = "app."; + public const string ACTION_QUIT = "action-quit"; + + private const ActionEntry[] ACTION_ENTRIES = { + { ACTION_QUIT, quit } + }; + construct { application_id = "io.elementary.onboarding"; flags = ApplicationFlags.FLAGS_NONE; @@ -18,6 +25,9 @@ public class Onboarding.App : Gtk.Application { Granite.init (); + add_action_entries (ACTION_ENTRIES, this); + set_accels_for_action (ACTION_PREFIX + ACTION_QUIT, {"Q"}); + var granite_settings = Granite.Settings.get_default (); var gtk_settings = Gtk.Settings.get_default ();