aboutsummaryrefslogtreecommitdiff
path: root/src/sound-service.c
diff options
context:
space:
mode:
authorConor Curran <conor.curran@canonical.com>2011-01-26 21:30:55 -0600
committerConor Curran <conor.curran@canonical.com>2011-01-26 21:30:55 -0600
commitf5aba239f02110c6f0ba2a6c88349c6e59771f65 (patch)
tree7ede9ec6731b75a310d0bcaad311ce9450a0e865 /src/sound-service.c
parente832a5fd618e30ea15029d4c029f8796eeb66078 (diff)
parent2015246e5146a5a03b6b0497aa8ce18a705bd724 (diff)
downloadayatana-indicator-sound-f5aba239f02110c6f0ba2a6c88349c6e59771f65.tar.gz
ayatana-indicator-sound-f5aba239f02110c6f0ba2a6c88349c6e59771f65.tar.bz2
ayatana-indicator-sound-f5aba239f02110c6f0ba2a6c88349c6e59771f65.zip
merged big refactor
Diffstat (limited to 'src/sound-service.c')
-rw-r--r--src/sound-service.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/sound-service.c b/src/sound-service.c
index defcb94..2cb33d3 100644
--- a/src/sound-service.c
+++ b/src/sound-service.c
@@ -1,5 +1,4 @@
/*
-This service primarily controls PulseAudio and is driven by the sound indicator menu on the panel.
Copyright 2010 Canonical Ltd.
Authors:
@@ -19,8 +18,9 @@ with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "sound-service.h"
-#include "dbus-menu-manager.h"
+
#include "pulse-manager.h"
+#include "sound-service-dbus.h"
#include "music-player-bridge.h"
static GMainLoop *mainloop = NULL;
@@ -40,8 +40,8 @@ service_shutdown (IndicatorService *service, gpointer user_data)
{
if (mainloop != NULL) {
g_debug("Service shutdown !");
- //close_pulse_activites();
- //g_main_loop_quit(mainloop);
+ close_pulse_activites();
+ g_main_loop_quit(mainloop);
}
return;
}
@@ -64,7 +64,9 @@ main (int argc, char ** argv)
INDICATOR_SERVICE_SIGNAL_SHUTDOWN,
G_CALLBACK(service_shutdown), NULL);
- DbusmenuMenuitem* root_menuitem = dbus_menu_manager_setup();
+ SoundServiceDbus* sound_service = g_object_new(SOUND_SERVICE_DBUS_TYPE, NULL);
+
+ DbusmenuMenuitem* root_menuitem = sound_service_dbus_create_root_item(sound_service);
MusicPlayerBridge* server = music_player_bridge_new();
music_player_bridge_set_root_menu_item(server, root_menuitem);