[gnome-settings-daemon] test-plugin: Call notify_init()



commit 7f7b720e4e5347d6ec1b568e75daf03b50765979
Author: Martin Pitt <martinpitt gnome org>
Date:   Thu Oct 11 10:06:51 2012 +0200

    test-plugin: Call notify_init()
    
    Call notify_init() in test-plugin.h, so that the gsd-tst-* wrapper programs can
    use notifications just like the plugins can when running under the real daemon.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=685936

 configure.ac                 |    1 +
 plugins/common/test-plugin.h |    2 ++
 2 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 95686da..15e381a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -69,6 +69,7 @@ PKG_CHECK_MODULES(SETTINGS_DAEMON,
 PKG_CHECK_MODULES(SETTINGS_PLUGIN,
         gtk+-3.0 >= $GTK_REQUIRED_VERSION
         gio-2.0 >= $GIO_REQUIRED_VERSION
+        libnotify >= $LIBNOTIFY_REQUIRED_VERSION,
         gsettings-desktop-schemas
         x11
 )
diff --git a/plugins/common/test-plugin.h b/plugins/common/test-plugin.h
index 6120cc0..f0100de 100644
--- a/plugins/common/test-plugin.h
+++ b/plugins/common/test-plugin.h
@@ -15,6 +15,7 @@
 
 #include <glib/gi18n.h>
 #include <gtk/gtk.h>
+#include <libnotify/notify.h>
 
 #ifndef SCHEMA_NAME
 #define SCHEMA_NAME PLUGIN_NAME
@@ -49,6 +50,7 @@ main (int argc, char **argv)
         bindtextdomain (GETTEXT_PACKAGE, GNOME_SETTINGS_LOCALEDIR);
         bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
         textdomain (GETTEXT_PACKAGE);
+        notify_init ("gnome-settings-daemon");
 
 	g_setenv ("G_MESSAGES_DEBUG", "all", TRUE);
 



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