[gnome-applets/wip/muktupavels/gresource] build: generate one GResource file for module



commit 94b9f2e15452bf33fab958973ce201b609e78297
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Sat Mar 28 19:15:10 2020 +0200

    build: generate one GResource file for module

 gnome-applets/Makefile.am                          | 64 ++++++++++++++++++++++
 gnome-applets/brightness/Makefile.am               |  8 ---
 gnome-applets/brightness/brightness-applet.c       |  7 +--
 gnome-applets/command/Makefile.am                  |  3 -
 gnome-applets/command/command-applet-menu.xml      | 14 +++++
 gnome-applets/command/command-applet.c             | 22 ++------
 gnome-applets/gweather/Makefile.am                 | 10 ----
 gnome-applets/gweather/gweather-applet.c           | 11 ++--
 gnome-applets/timer/Makefile.am                    |  1 -
 gnome-applets/timer/timer-applet-menu.xml          | 26 +++++++++
 gnome-applets/timer/timer-applet.c                 | 34 ++----------
 gnome-applets/trash/Makefile.am                    | 19 -------
 gnome-applets/trash/trash-applet.c                 |  2 +-
 gnome-applets/trash/trash-empty.c                  |  2 +-
 gnome-applets/trash/trash-resources.gresource.xml  |  7 ---
 gnome-applets/window-picker/Makefile.am            | 20 -------
 gnome-applets/window-picker/wp-about-dialog.c      |  4 +-
 gnome-applets/window-picker/wp-applet.c            |  3 +-
 .../window-picker/wp-preferences-dialog.c          |  4 +-
 .../window-picker/wp-resources.gresource.xml       |  8 ---
 po/POTFILES.in                                     |  2 +
 21 files changed, 131 insertions(+), 140 deletions(-)
---
diff --git a/gnome-applets/Makefile.am b/gnome-applets/Makefile.am
index 6ee4125fe..23af298fb 100644
--- a/gnome-applets/Makefile.am
+++ b/gnome-applets/Makefile.am
@@ -27,6 +27,7 @@ org_gnome_gnome_applets_la_CFLAGS = \
 
 org_gnome_gnome_applets_la_SOURCES = \
        ga-module.c \
+       $(BUILT_SOURCES) \
        $(NULL)
 
 org_gnome_gnome_applets_la_LIBADD = \
@@ -44,4 +45,67 @@ org_gnome_gnome_applets_la_LDFLAGS = \
        $(AM_LDFLAGS) \
        $(NULL)
 
+icon_files = \
+       window-picker/wp-about-logo.png \
+       $(NULL)
+
+ui_files = \
+       brightness/brightness-applet-menu.xml \
+       command/command-applet-menu.xml \
+       gweather/gweather-applet-menu.xml \
+       timer/timer-applet-menu.xml \
+       trash/trash-empty.ui \
+       trash/trash-menu.xml \
+       window-picker/wp-menu.xml \
+       window-picker/wp-preferences-dialog.ui \
+       $(NULL)
+
+gnome-applets.gresource.xml: Makefile
+       $(AM_V_GEN) echo '<?xml version="1.0" encoding="UTF-8"?>' > $@; \
+               echo '<gresources>' >> $@; \
+               echo '  <gresource prefix="/org/gnome/gnome-applets/icons">' >> $@; \
+               for f in $(icon_files); do \
+               b=`basename $$f`; \
+               echo "    <file compressed=\"true\" alias=\"$$b\">$$f</file>" >> $@; \
+               done; \
+               echo '  </gresource>' >> $@; \
+               echo '  <gresource prefix="/org/gnome/gnome-applets/ui">' >> $@; \
+               for f in $(ui_files); do \
+               b=`basename $$f`; \
+               echo "    <file compressed=\"true\" preprocess=\"xml-stripblanks\" alias=\"$$b\">$$f</file>" 
$@; \
+               done; \
+               echo '  </gresource>' >> $@; \
+               echo '</gresources>' >> $@;
+
+resource_files = \
+       $(shell $(GLIB_COMPILE_RESOURCES) \
+               --sourcedir=$(srcdir) \
+               --generate-dependencies \
+               $(builddir)/gnome-applets.gresource.xml)
+
+ga-resources.c: gnome-applets.gresource.xml $(resource_files)
+       $(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) \
+               --target=$@ --sourcedir=$(srcdir) \
+               --generate --c-name ga $<
+
+ga-resources.h: gnome-applets.gresource.xml
+       $(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) \
+               --target=$@ --sourcedir=$(srcdir) \
+               --generate --c-name ga $<
+
+BUILT_SOURCES = \
+       ga-resources.c \
+       ga-resources.h \
+       $(NULL)
+
+CLEANFILES = \
+       gnome-applets.gresource.xml \
+       $(BUILT_SOURCES) \
+       $(NULL)
+
+EXTRA_DIST = \
+       $(icon_files) \
+       $(ui_files) \
+       $(NULL)
+
 -include $(top_srcdir)/git.mk
diff --git a/gnome-applets/brightness/Makefile.am b/gnome-applets/brightness/Makefile.am
index 24d3f8565..60ee8302a 100644
--- a/gnome-applets/brightness/Makefile.am
+++ b/gnome-applets/brightness/Makefile.am
@@ -1,15 +1,8 @@
 NULL =
 
-uidir = $(pkgdatadir)/ui
-ui_DATA = brightness-applet-menu.xml
-
 noinst_LTLIBRARIES = libbrightness-applet.la
 
 libbrightness_applet_la_CPPFLAGS = \
-       -I. \
-       -I$(srcdir) \
-       -DBRIGHTNESS_MENU_UI_DIR=\""$(uidir)"\" \
-       -DPKG_DATA_DIR=\""$(pkgdatadir)"\" \
        -DG_LOG_DOMAIN=\"org.gnome.gnome-applets.brightness\" \
        -DG_LOG_USE_STRUCTURED=1 \
        $(NULL)
@@ -56,7 +49,6 @@ CLEANFILES = \
 
 EXTRA_DIST = \
        org.gnome.SettingsDaemon.Power.Screen.xml \
-       $(ui_DATA) \
        $(NULL)
 
 -include $(top_srcdir)/git.mk
diff --git a/gnome-applets/brightness/brightness-applet.c b/gnome-applets/brightness/brightness-applet.c
index 0556efe64..429c46d76 100644
--- a/gnome-applets/brightness/brightness-applet.c
+++ b/gnome-applets/brightness/brightness-applet.c
@@ -771,7 +771,7 @@ gpm_brightness_applet_name_vanished_cb (GDBusConnection *connection, const gchar
 static void
 gpm_brightness_applet_init (GpmBrightnessApplet *applet)
 {
-       gchar *ui_path;
+       const char *menu_resource;
 
        /* initialize fields */
        applet->popped = FALSE;
@@ -800,9 +800,8 @@ gpm_brightness_applet_init (GpmBrightnessApplet *applet)
        gtk_container_add (GTK_CONTAINER (applet), applet->image);
 
        /* menu */
-       ui_path = g_build_filename (BRIGHTNESS_MENU_UI_DIR, "brightness-applet-menu.xml", NULL);
-       gp_applet_setup_menu_from_file (GP_APPLET (applet), ui_path, menu_actions);
-       g_free (ui_path);
+       menu_resource = "/org/gnome/gnome-applets/ui/brightness-applet-menu.xml";
+       gp_applet_setup_menu_from_resource (GP_APPLET (applet), menu_resource, menu_actions);
 
        /* show */
        gtk_widget_show_all (GTK_WIDGET(applet));
diff --git a/gnome-applets/command/Makefile.am b/gnome-applets/command/Makefile.am
index f743d15bf..9f806c2cd 100644
--- a/gnome-applets/command/Makefile.am
+++ b/gnome-applets/command/Makefile.am
@@ -3,9 +3,6 @@ NULL =
 noinst_LTLIBRARIES = libcommand-applet.la
 
 libcommand_applet_la_CPPFLAGS = \
-       -I. \
-       -I$(srcdir) \
-       -DPKG_DATA_DIR=\""$(pkgdatadir)"\" \
        -DG_LOG_DOMAIN=\"org.gnome.gnome-applets.command\" \
        -DG_LOG_USE_STRUCTURED=1 \
        $(NULL)
diff --git a/gnome-applets/command/command-applet-menu.xml b/gnome-applets/command/command-applet-menu.xml
new file mode 100644
index 000000000..fa8765911
--- /dev/null
+++ b/gnome-applets/command/command-applet-menu.xml
@@ -0,0 +1,14 @@
+<interface>
+  <menu id="command-menu">
+    <section>
+      <item>
+        <attribute name="label" translatable="yes">_Preferences</attribute>
+        <attribute name="action">command.preferences</attribute>
+      </item>
+      <item>
+        <attribute name="label" translatable="yes">_About</attribute>
+        <attribute name="action">command.about</attribute>
+      </item>
+    </section>
+  </menu>
+</interface>
diff --git a/gnome-applets/command/command-applet.c b/gnome-applets/command/command-applet.c
index 07faa12bd..deab9ef70 100644
--- a/gnome-applets/command/command-applet.c
+++ b/gnome-applets/command/command-applet.c
@@ -74,21 +74,6 @@ static const GActionEntry applet_menu_actions [] = {
     {NULL}
 };
 
-static const char *ui = "<interface>\
-    <menu id=\"command-menu\">\
-    <section>\
-      <item>\
-        <attribute name=\"label\" translatable=\"yes\">_Preferences</attribute>\
-        <attribute name=\"action\">command.preferences</attribute>\
-      </item>\
-      <item>\
-        <attribute name=\"label\" translatable=\"yes\">_About</attribute>\
-        <attribute name=\"action\">command.about</attribute>\
-      </item>\
-    </section>\
-    </menu>\
-    </interface>";
-
 /* Show the about dialog */
 static void
 command_about_callback (GSimpleAction *action, GVariant *parameter, gpointer data)
@@ -328,6 +313,8 @@ settings_interval_changed (GSettings     *settings,
 static void
 command_applet_fill (CommandApplet *command_applet)
 {
+    const char *menu_resource;
+
     command_applet->settings = gp_applet_settings_new (GP_APPLET (command_applet),
                                                        COMMAND_SCHEMA);
 
@@ -372,7 +359,10 @@ command_applet_fill (CommandApplet *command_applet)
                      G_SETTINGS_BIND_DEFAULT);
 
     /* set up context menu */
-    gp_applet_setup_menu (GP_APPLET (command_applet), ui, applet_menu_actions);
+    menu_resource = "/org/gnome/gnome-applets/ui/command-applet-menu.xml";
+    gp_applet_setup_menu_from_resource (GP_APPLET (command_applet),
+                                        menu_resource,
+                                        applet_menu_actions);
 
     /* first command execution */
     create_command (command_applet);
diff --git a/gnome-applets/gweather/Makefile.am b/gnome-applets/gweather/Makefile.am
index 265753d24..5305eb7c2 100644
--- a/gnome-applets/gweather/Makefile.am
+++ b/gnome-applets/gweather/Makefile.am
@@ -1,14 +1,8 @@
 NULL =
 
-uidir = $(pkgdatadir)/ui
-ui_DATA = gweather-applet-menu.xml
-
 noinst_LTLIBRARIES = libgweather-applet.la
 
 libgweather_applet_la_CPPFLAGS = \
-       -I$(srcdir) \
-       -I$(top_srcdir) \
-       -DGWEATHER_MENU_UI_DIR=\""$(uidir)"\" \
        -DG_LOG_DOMAIN=\"org.gnome.gnome-applets.gweather\" \
        -DG_LOG_USE_STRUCTURED=1 \
        $(NULL)
@@ -45,8 +39,4 @@ libgweather_applet_la_LIBADD = \
        $(XML2_LIBS) \
        $(NULL)
 
-EXTRA_DIST = \
-       $(ui_DATA) \
-       $(NULL)
-
 -include $(top_srcdir)/git.mk
diff --git a/gnome-applets/gweather/gweather-applet.c b/gnome-applets/gweather/gweather-applet.c
index 9c6772abc..651089945 100644
--- a/gnome-applets/gweather/gweather-applet.c
+++ b/gnome-applets/gweather/gweather-applet.c
@@ -394,7 +394,7 @@ applet_destroy (GtkWidget *widget, GWeatherApplet *gw_applet)
 void gweather_applet_create (GWeatherApplet *gw_applet)
 {
     GAction *action;
-    gchar          *ui_path;
+    const char *menu_resource;
     AtkObject      *atk_obj;
     GNetworkMonitor*monitor;
 
@@ -420,11 +420,10 @@ void gweather_applet_create (GWeatherApplet *gw_applet)
     if (GTK_IS_ACCESSIBLE (atk_obj))
           atk_object_set_name (atk_obj, _("GNOME Weather"));
 
-    ui_path = g_build_filename (GWEATHER_MENU_UI_DIR, "gweather-applet-menu.xml", NULL);
-    gp_applet_setup_menu_from_file (GP_APPLET (gw_applet),
-                                    ui_path,
-                                    weather_applet_menu_actions);
-    g_free (ui_path);
+    menu_resource = "/org/gnome/gnome-applets/ui/gweather-applet-menu.xml";
+    gp_applet_setup_menu_from_resource (GP_APPLET (gw_applet),
+                                        menu_resource,
+                                        weather_applet_menu_actions);
 
     action = gp_applet_menu_lookup_action (GP_APPLET (gw_applet), "preferences");
        g_object_bind_property (gw_applet, "locked-down", action, "enabled",
diff --git a/gnome-applets/timer/Makefile.am b/gnome-applets/timer/Makefile.am
index 35b39096d..93c691df9 100644
--- a/gnome-applets/timer/Makefile.am
+++ b/gnome-applets/timer/Makefile.am
@@ -5,7 +5,6 @@ noinst_LTLIBRARIES = libtimer-applet.la
 libtimer_applet_la_CPPFLAGS = \
        -DG_LOG_DOMAIN=\"org.gnome.gnome-applets.timer\" \
        -DG_LOG_USE_STRUCTURED=1 \
-       -DPKG_DATA_DIR=\""$(pkgdatadir)"\" \
        $(NULL)
 
 libtimer_applet_la_CFLAGS = \
diff --git a/gnome-applets/timer/timer-applet-menu.xml b/gnome-applets/timer/timer-applet-menu.xml
new file mode 100644
index 000000000..4bf6c05f0
--- /dev/null
+++ b/gnome-applets/timer/timer-applet-menu.xml
@@ -0,0 +1,26 @@
+<interface>
+  <menu id="timer-menu">
+    <section>
+      <item>
+        <attribute name="label" translatable="yes">_Start timer</attribute>
+        <attribute name="action">timer.start</attribute>
+      </item>
+      <item>
+        <attribute name="label" translatable="yes">_P_ause timer</attribute>
+        <attribute name="action">timer.pause</attribute>
+      </item>
+      <item>
+        <attribute name="label" translatable="yes">S_top timer</attribute>
+        <attribute name="action">timer.stop</attribute>
+      </item>
+      <item>
+        <attribute name="label" translatable="yes">_Preferences</attribute>
+        <attribute name="action">timer.preferences</attribute>
+      </item>
+      <item>
+        <attribute name="label" translatable="yes">_About</attribute>
+        <attribute name="action">timer.about</attribute>
+      </item>
+    </section>
+  </menu>
+</interface>
diff --git a/gnome-applets/timer/timer-applet.c b/gnome-applets/timer/timer-applet.c
index 6520e711c..a1382c464 100644
--- a/gnome-applets/timer/timer-applet.c
+++ b/gnome-applets/timer/timer-applet.c
@@ -82,33 +82,6 @@ static const GActionEntry applet_menu_actions [] = {
     {NULL}
 };
 
-static const char *ui = "<interface>\
-      <menu id=\"timer-menu\">\
-      <section>\
-      <item>\
-        <attribute name=\"label\" translatable=\"yes\">_Start timer</attribute>\
-        <attribute name=\"action\">timer.start</attribute>\
-      </item>\
-      <item>\
-        <attribute name=\"label\" translatable=\"yes\">_P_ause timer</attribute>\
-        <attribute name=\"action\">timer.pause</attribute>\
-      </item>\
-      <item>\
-        <attribute name=\"label\" translatable=\"yes\">S_top timer</attribute>\
-        <attribute name=\"action\">timer.stop</attribute>\
-      </item>\
-      <item>\
-        <attribute name=\"label\" translatable=\"yes\">_Preferences</attribute>\
-        <attribute name=\"action\">timer.preferences</attribute>\
-      </item>\
-      <item>\
-        <attribute name=\"label\" translatable=\"yes\">_About</attribute>\
-        <attribute name=\"action\">timer.about</attribute>\
-      </item>\
-    </section>\
-    </menu>\
-    </interface>";
-
 /* timer management */
 static gboolean
 timer_callback (TimerApplet *applet)
@@ -384,6 +357,8 @@ timer_settings_changed (GSettings *settings, gchar *key, TimerApplet *applet)
 static void
 timer_applet_fill (TimerApplet *applet)
 {
+    const char *menu_resource;
+
     applet->settings = gp_applet_settings_new (GP_APPLET (applet), TIMER_SCHEMA);
     applet->timeout_id = 0;
     applet->active = FALSE;
@@ -414,7 +389,10 @@ timer_applet_fill (TimerApplet *applet)
     gtk_widget_hide (GTK_WIDGET (applet->pause_image));
 
     /* set up context menu */
-    gp_applet_setup_menu (GP_APPLET (applet), ui, applet_menu_actions);
+    menu_resource = "/org/gnome/gnome-applets/ui/timer-applet-menu.xml";
+    gp_applet_setup_menu_from_resource (GP_APPLET (applet),
+                                        menu_resource,
+                                        applet_menu_actions);
 
     /* execute callback to set actions sensitiveness */
     timer_callback (applet);
diff --git a/gnome-applets/trash/Makefile.am b/gnome-applets/trash/Makefile.am
index 3e415ac3f..4df13efc5 100644
--- a/gnome-applets/trash/Makefile.am
+++ b/gnome-applets/trash/Makefile.am
@@ -32,25 +32,6 @@ libtrash_applet_la_SOURCES = \
        trash-applet.h \
        trash-empty.h \
        trash-empty.c \
-       trash-resources.c \
-       trash-resources.h \
-       $(NULL)
-
-trash-resources.c: trash-resources.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) 
--generate-dependencies $(srcdir)/trash-resources.gresource.xml)
-       $(AM_V_GEN)$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(srcdir) --generate --c-name trash $<
-
-trash-resources.h: trash-resources.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) 
--generate-dependencies $(srcdir)/trash-resources.gresource.xml)
-       $(AM_V_GEN)$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(srcdir) --generate --c-name trash $<
-
-EXTRA_DIST = \
-       trash-empty.ui \
-       trash-menu.xml \
-       trash-resources.gresource.xml \
-       $(NULL)
-
-CLEANFILES = \
-       trash-resources.c \
-       trash-resources.h \
        $(NULL)
 
 -include $(top_srcdir)/git.mk
diff --git a/gnome-applets/trash/trash-applet.c b/gnome-applets/trash/trash-applet.c
index b45a52e21..3efd05450 100644
--- a/gnome-applets/trash/trash-applet.c
+++ b/gnome-applets/trash/trash-applet.c
@@ -565,7 +565,7 @@ trash_applet_init (TrashApplet *self)
   gp_applet_set_flags (GP_APPLET (self), GP_APPLET_FLAGS_EXPAND_MINOR);
 
   /* Set up the menu */
-  resource_name = "/org/gnome/gnome-applets/trash/trash-menu.xml";
+  resource_name = "/org/gnome/gnome-applets/ui/trash-menu.xml";
   gp_applet_setup_menu_from_resource (GP_APPLET (self),
                                       resource_name,
                                       trash_applet_menu_actions);
diff --git a/gnome-applets/trash/trash-empty.c b/gnome-applets/trash/trash-empty.c
index 637b3c70f..6bde8af4f 100644
--- a/gnome-applets/trash/trash-empty.c
+++ b/gnome-applets/trash/trash-empty.c
@@ -237,7 +237,7 @@ trash_empty_start (GtkWidget *parent)
 
   builder = gtk_builder_new ();
 
-  resource_name = "/org/gnome/gnome-applets/trash/trash-empty.ui";
+  resource_name = "/org/gnome/gnome-applets/ui/trash-empty.ui";
 
   gtk_builder_add_from_resource (builder, resource_name, NULL);
 
diff --git a/gnome-applets/window-picker/Makefile.am b/gnome-applets/window-picker/Makefile.am
index 85453372e..88d0c90ff 100644
--- a/gnome-applets/window-picker/Makefile.am
+++ b/gnome-applets/window-picker/Makefile.am
@@ -39,28 +39,8 @@ libwindow_picker_applet_la_SOURCES = \
        task-item.h \
        task-list.c \
        task-list.h \
-       wp-resources.c \
-       wp-resources.h \
        wp-task-title.c \
        wp-task-title.h \
        $(NULL)
 
-wp-resources.c: wp-resources.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) 
--generate-dependencies $(srcdir)/wp-resources.gresource.xml)
-       $(AM_V_GEN)$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(srcdir) --generate --c-name wp $<
-
-wp-resources.h: wp-resources.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) 
--generate-dependencies $(srcdir)/wp-resources.gresource.xml)
-       $(AM_V_GEN)$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(srcdir) --generate --c-name wp $<
-
-EXTRA_DIST = \
-       wp-about-logo.png \
-       wp-menu.xml \
-       wp-preferences-dialog.ui \
-       wp-resources.gresource.xml \
-       $(NULL)
-
-CLEANFILES = \
-       wp-resources.c \
-       wp-resources.h \
-       $(NULL)
-
 -include $(top_srcdir)/git.mk
diff --git a/gnome-applets/window-picker/wp-about-dialog.c b/gnome-applets/window-picker/wp-about-dialog.c
index 9239be3cb..292a3ef7b 100644
--- a/gnome-applets/window-picker/wp-about-dialog.c
+++ b/gnome-applets/window-picker/wp-about-dialog.c
@@ -27,8 +27,6 @@
 
 #include "wp-about-dialog.h"
 
-#define GRESOURCE "/org/gnome/gnome-applets/window-picker/"
-
 struct _WpAboutDialog
 {
   GtkAboutDialog  parent;
@@ -52,7 +50,7 @@ wp_about_dialog_constructed (GObject *object)
   G_OBJECT_CLASS (wp_about_dialog_parent_class)->constructed (object);
 
   dialog = WP_ABOUT_DIALOG (object);
-  resource = GRESOURCE "wp-about-logo.png";
+  resource = "/org/gnome/gnome-applets/icons/wp-about-logo.png";
 
   dialog->logo = gdk_pixbuf_new_from_resource (resource, NULL);
 
diff --git a/gnome-applets/window-picker/wp-applet.c b/gnome-applets/window-picker/wp-applet.c
index f30438ead..23d452186 100644
--- a/gnome-applets/window-picker/wp-applet.c
+++ b/gnome-applets/window-picker/wp-applet.c
@@ -37,7 +37,6 @@
 #include "wp-task-title.h"
 
 #define SETTINGS_SCHEMA "org.gnome.gnome-applets.window-picker-applet"
-#define GRESOURCE "/org/gnome/gnome-applets/window-picker/"
 #define TITLE_BUTTON_SPACE 6
 #define CONTAINER_SPACING 10
 
@@ -155,7 +154,7 @@ wp_applet_setup_menu (GpApplet *applet)
 {
   const gchar *resource_name;
 
-  resource_name = GRESOURCE "wp-menu.xml";
+  resource_name = "/org/gnome/gnome-applets/ui/wp-menu.xml";
 
   gp_applet_setup_menu_from_resource (applet, resource_name, menu_actions);
 }
diff --git a/gnome-applets/window-picker/wp-preferences-dialog.c 
b/gnome-applets/window-picker/wp-preferences-dialog.c
index 7cb2a4d67..0a254df8e 100644
--- a/gnome-applets/window-picker/wp-preferences-dialog.c
+++ b/gnome-applets/window-picker/wp-preferences-dialog.c
@@ -25,8 +25,6 @@
 
 #include "wp-preferences-dialog.h"
 
-#define GRESOURCE "/org/gnome/gnome-applets/window-picker/"
-
 struct _WpPreferencesDialog
 {
   GtkDialog  parent;
@@ -133,7 +131,7 @@ wp_preferences_dialog_class_init (WpPreferencesDialogClass *dialog_class)
 
   g_object_class_install_properties (object_class, LAST_PROP, properties);
 
-  resource_name = GRESOURCE "wp-preferences-dialog.ui";
+  resource_name = "/org/gnome/gnome-applets/ui/wp-preferences-dialog.ui";
   gtk_widget_class_set_template_from_resource (widget_class, resource_name);
 
   gtk_widget_class_bind_template_child (widget_class, WpPreferencesDialog,
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 77fa176a4..813fe7cc4 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -45,12 +45,14 @@ geyes/src/geyes.c
 geyes/src/themes.c
 [type: gettext/glade]gnome-applets/brightness/brightness-applet-menu.xml
 gnome-applets/brightness/brightness-applet.c
+[type: gettext/glade]gnome-applets/command/command-applet-menu.xml
 gnome-applets/command/command-applet.c
 gnome-applets/ga-module.c
 [type: gettext/glade]gnome-applets/gweather/gweather-applet-menu.xml
 gnome-applets/gweather/gweather-applet.c
 gnome-applets/gweather/gweather-dialog.c
 gnome-applets/gweather/gweather-pref.c
+[type: gettext/glade]gnome-applets/timer/timer-applet-menu.xml
 gnome-applets/timer/timer-applet.c
 gnome-applets/trash/trash-applet.c
 gnome-applets/trash/trash-empty.c


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