[totem/wip/hadess/interface-load: 1/6] main: Build shortcuts dialogue from resource




commit bf0b782d635c5209e62e848aea328b94dbf0393f
Author: Bastien Nocera <hadess hadess net>
Date:   Wed Mar 30 14:15:12 2022 +0200

    main: Build shortcuts dialogue from resource

 data/meson.build         | 1 -
 data/totem.gresource.xml | 1 +
 src/totem-object.c       | 2 +-
 3 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/data/meson.build b/data/meson.build
index 669621981..51e2bb5f9 100644
--- a/data/meson.build
+++ b/data/meson.build
@@ -37,7 +37,6 @@ else
 endif
 
 ui_files = files(
-  'shortcuts.ui',
   'totem.ui',
 )
 
diff --git a/data/totem.gresource.xml b/data/totem.gresource.xml
index 97e6f60ec..d5f6061de 100644
--- a/data/totem.gresource.xml
+++ b/data/totem.gresource.xml
@@ -4,5 +4,6 @@
     <file compressed="true">totem-preferences-dialog.ui</file>
     <file compressed="true">playlist.ui</file>
     <file compressed="true">uri.ui</file>
+    <file compressed="true">shortcuts.ui</file>
   </gresource>
 </gresources>
diff --git a/src/totem-object.c b/src/totem-object.c
index bd9ecc6d1..01a2d3c2d 100644
--- a/src/totem-object.c
+++ b/src/totem-object.c
@@ -2317,7 +2317,7 @@ totem_object_show_keyboard_shortcuts (TotemObject *totem)
                return;
        }
 
-       builder = totem_interface_load ("shortcuts.ui", FALSE, NULL, NULL);
+       builder = gtk_builder_new_from_resource ("/org/gnome/totem/ui/shortcuts.ui");
        totem->shortcuts_win = GTK_WINDOW (gtk_builder_get_object (builder, "shortcuts-totem"));
        gtk_window_set_transient_for (totem->shortcuts_win, GTK_WINDOW (totem->win));
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]