diff options
author | Bastien Nocera <hadess@hadess.net> | 2014-10-20 18:32:19 +0200 |
---|---|---|
committer | Bastien Nocera <hadess@hadess.net> | 2014-10-20 18:55:34 +0200 |
commit | 03cf464b38fc110621d38435ddf74cee35b9bbb5 (patch) | |
tree | 8915504decd4fe9213e7e3d789223a6cb1df4b61 /src/totem-menu.c | |
parent | dd6049bbcaf2d5e09c178639c51d2572bd6f0909 (diff) | |
download | totem-03cf464b38fc110621d38435ddf74cee35b9bbb5.tar.gz |
main: Register GActions early
Register the GActions early, so that they are available even when
the main window isn't. This is necessary to make remote commands
available on D-Bus.
Diffstat (limited to 'src/totem-menu.c')
-rw-r--r-- | src/totem-menu.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/totem-menu.c b/src/totem-menu.c index 7ac40bfbf..76a4a153d 100644 --- a/src/totem-menu.c +++ b/src/totem-menu.c @@ -321,13 +321,17 @@ static GActionEntry app_entries[] = { }; void +totem_app_actions_setup (Totem *totem) +{ + g_action_map_add_action_entries (G_ACTION_MAP (totem), app_entries, G_N_ELEMENTS (app_entries), totem); +} + +void totem_app_menu_setup (Totem *totem) { GMenuModel *appmenu; char *accels[] = { NULL, NULL }; - g_action_map_add_action_entries (G_ACTION_MAP (totem), app_entries, G_N_ELEMENTS (app_entries), totem); - appmenu = (GMenuModel *)gtk_builder_get_object (totem->xml, "appmenu"); gtk_application_set_app_menu (GTK_APPLICATION (totem), appmenu); |