[rhythmbox] notification: don't create a notification on startup



commit 64d77ff358333d0b724739359b08ea6fe2408378
Author: Jonathan Matthew <jonathan d14n org>
Date:   Wed Jul 20 09:01:55 2011 +1000

    notification: don't create a notification on startup
    
    https://bugzilla.gnome.org/show_bug.cgi?id=652217

 plugins/notification/rb-notification-plugin.c |   26 -------------------------
 1 files changed, 0 insertions(+), 26 deletions(-)
---
diff --git a/plugins/notification/rb-notification-plugin.c b/plugins/notification/rb-notification-plugin.c
index 0d1c271..9aff54c 100644
--- a/plugins/notification/rb-notification-plugin.c
+++ b/plugins/notification/rb-notification-plugin.c
@@ -534,7 +534,6 @@ static void
 impl_activate (PeasActivatable *bplugin)
 {
 	RBNotificationPlugin *plugin;
-	GDBusConnection *bus;
 	RBShell *shell;
 
 	rb_debug ("activating notification plugin");
@@ -561,31 +560,6 @@ impl_activate (PeasActivatable *bplugin)
 	g_signal_connect_object (plugin->db, "entry_extra_metadata_notify::" RHYTHMDB_PROP_STREAM_SONG_ALBUM,
 				 G_CALLBACK (db_stream_metadata_cb), plugin, 0);
 
-	/* create resident notification on startup when running in GNOME Shell */
-	bus = g_bus_get_sync (G_BUS_TYPE_SESSION, NULL, NULL);
-	if (bus != NULL) {
-		GVariant *result;
-		result = g_dbus_connection_call_sync (bus,
-						      "org.freedesktop.DBus",
-						      "/org/freedesktop/DBus",
-						      "org.freedesktop.DBus",
-						      "GetNameOwner",
-						      g_variant_new ("(s)", "org.gnome.Shell"),
-						      G_VARIANT_TYPE ("(s)"),
-						      G_DBUS_CALL_FLAGS_NONE,
-						      -1,
-						      NULL,
-						      NULL);
-		if (result != NULL) {
-			rb_debug ("GNOME Shell is running");
-			notify_playing_entry (plugin, FALSE);
-			g_variant_unref (result);
-		} else {
-			rb_debug ("GNOME Shell isn't running");
-		}
-		g_object_unref (bus);
-	}
-
 	/* hook into shell preferences so we can poke stuff into the general prefs page? */
 
 	g_object_unref (shell);



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