From 3a1bf21052b1f9939ef574a4dfa6d4c1fe74df5d Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Tue, 10 Jan 2012 18:04:50 +0100 Subject: make indicator-sound's schema and path naming consistent with other indicators. indicator-sound uses a different schema prefix ("/com/canonical/indicators" vs "/com/canonical/indicator") and different path prefix ("/apps/indicators" vs "/com/canonical/indicator") than other indicators use. When I asked ronoc about the latter, he confirmed it's an error and suggested that the former be fixed at the same time to make indicator naming more consistent. --- data/Makefile.am | 2 +- data/com.canonical.indicator.sound.gschema.xml | 38 +++++++++++++++++++++++++ data/com.canonical.indicators.sound.gschema.xml | 38 ------------------------- data/indicator-sound.service.in | 2 +- src/dbus-shared-names.h | 8 +++--- src/familiar-players-db.vala | 2 +- src/metadata-menu-item.vala | 2 +- src/pulseaudio-mgr.c | 2 +- src/settings-manager.vala | 2 +- src/sound-service-dbus.c | 4 +-- src/sound-service.xml | 4 +-- src/sound-state-manager.c | 2 +- 12 files changed, 53 insertions(+), 53 deletions(-) create mode 100644 data/com.canonical.indicator.sound.gschema.xml delete mode 100644 data/com.canonical.indicators.sound.gschema.xml diff --git a/data/Makefile.am b/data/Makefile.am index f33b470..2891606 100644 --- a/data/Makefile.am +++ b/data/Makefile.am @@ -1,7 +1,7 @@ SUBDIRS = icons gsettings_SCHEMAS = \ - com.canonical.indicators.sound.gschema.xml + com.canonical.indicator.sound.gschema.xml @GSETTINGS_RULES@ dbus_servicesdir = $(DBUSSERVICEDIR) diff --git a/data/com.canonical.indicator.sound.gschema.xml b/data/com.canonical.indicator.sound.gschema.xml new file mode 100644 index 0000000..5d3fea8 --- /dev/null +++ b/data/com.canonical.indicator.sound.gschema.xml @@ -0,0 +1,38 @@ + + + + A list of applications blacklisted from the sound menu + [] + + Each media player which abides by the MPRIS2 spec will automatically appear in the menu. + This array should contain the desktop file names (minus .desktop suffix) of applications which + do not want to be included in the sound menu. + + + + A list of applications which at some point have registered with the sound menu + [ 'banshee' ] + + Each media player which abides by the MPRIS2 spec will automatically appear in the menu. + This array should contain the desktop file names (minus .desktop suffix) of applications which + have at some point appeared in the menU. This allows the menu remember and display offlined applications. + + + + false + Initial setting for global mute (mute all) on the menu + + On start up volume should not be muted. + + + + true + Initial setting for showing notify-osd notification on scroll volume-change + + When using the mouse scroll-wheel over the indicator-sound icon, the volume changes. + Enabling this setting, every scroll volume-change a notify-osd bubble with the + updated volume value will be shown (if supported by your notification daemon). + + + + diff --git a/data/com.canonical.indicators.sound.gschema.xml b/data/com.canonical.indicators.sound.gschema.xml deleted file mode 100644 index dc63bcb..0000000 --- a/data/com.canonical.indicators.sound.gschema.xml +++ /dev/null @@ -1,38 +0,0 @@ - - - - A list of applications blacklisted from the sound menu - [] - - Each media player which abides by the MPRIS2 spec will automatically appear in the menu. - This array should contain the desktop file names (minus .desktop suffix) of applications which - do not want to be included in the sound menu. - - - - A list of applications which at some point have registered with the sound menu - [ 'banshee' ] - - Each media player which abides by the MPRIS2 spec will automatically appear in the menu. - This array should contain the desktop file names (minus .desktop suffix) of applications which - have at some point appeared in the menU. This allows the menu remember and display offlined applications. - - - - false - Initial setting for global mute (mute all) on the menu - - On start up volume should not be muted. - - - - true - Initial setting for showing notify-osd notification on scroll volume-change - - When using the mouse scroll-wheel over the indicator-sound icon, the volume changes. - Enabling this setting, every scroll volume-change a notify-osd bubble with the - updated volume value will be shown (if supported by your notification daemon). - - - - diff --git a/data/indicator-sound.service.in b/data/indicator-sound.service.in index a80cd03..4cee062 100644 --- a/data/indicator-sound.service.in +++ b/data/indicator-sound.service.in @@ -1,3 +1,3 @@ [D-BUS Service] -Name=com.canonical.indicators.sound +Name=com.canonical.indicator.sound Exec=@libexecdir@/indicator-sound-service diff --git a/src/dbus-shared-names.h b/src/dbus-shared-names.h index 346a031..2517eb9 100644 --- a/src/dbus-shared-names.h +++ b/src/dbus-shared-names.h @@ -25,10 +25,10 @@ with this program. If not, see . #ifndef __DBUS_SHARED_NAMES_H__ #define __DBUS_SHARED_NAMES_H__ -#define INDICATOR_SOUND_DBUS_NAME "com.canonical.indicators.sound" -#define INDICATOR_SOUND_MENU_DBUS_OBJECT_PATH "/com/canonical/indicators/sound/menu" -#define INDICATOR_SOUND_SERVICE_DBUS_OBJECT_PATH "/com/canonical/indicators/sound/service" -#define INDICATOR_SOUND_DBUS_INTERFACE "com.canonical.indicators.sound" +#define INDICATOR_SOUND_DBUS_NAME "com.canonical.indicator.sound" +#define INDICATOR_SOUND_MENU_DBUS_OBJECT_PATH "/com/canonical/indicator/sound/menu" +#define INDICATOR_SOUND_SERVICE_DBUS_OBJECT_PATH "/com/canonical/indicator/sound/service" +#define INDICATOR_SOUND_DBUS_INTERFACE "com.canonical.indicator.sound" #define INDICATOR_SOUND_DBUS_VERSION 0 #define INDICATOR_SOUND_SIGNAL_STATE_UPDATE "SoundStateUpdate" diff --git a/src/familiar-players-db.vala b/src/familiar-players-db.vala index 96d690a..c47a35d 100644 --- a/src/familiar-players-db.vala +++ b/src/familiar-players-db.vala @@ -45,7 +45,7 @@ public class FamiliarPlayersDB : GLib.Object this.write_db(); } - this.dir_name = build_filename(get_user_cache_dir(), "indicators", "sound"); + this.dir_name = build_filename(get_user_cache_dir(), "indicator", "sound"); this.file_name = build_filename(this.dir_name, "familiar-players-db.keyfile"); if(create_key_file() && check_for_keys() && load_data_from_key_file()){ debug("keyfiles in place and ready for action"); diff --git a/src/metadata-menu-item.vala b/src/metadata-menu-item.vala index 995d248..623aaf5 100644 --- a/src/metadata-menu-item.vala +++ b/src/metadata-menu-item.vala @@ -24,7 +24,7 @@ using Gdk; public class MetadataMenuitem : PlayerItem { - public const string ALBUM_ART_DIR_SUFFIX = "indicators/sound/album-art-cache"; + public const string ALBUM_ART_DIR_SUFFIX = "indicator/sound/album-art-cache"; public static string album_art_cache_dir; private static FetchFile fetcher; diff --git a/src/pulseaudio-mgr.c b/src/pulseaudio-mgr.c index ad6d34f..ba83c71 100644 --- a/src/pulseaudio-mgr.c +++ b/src/pulseaudio-mgr.c @@ -138,7 +138,7 @@ reconnect_to_pulse (gpointer user_data) "Indicator Sound"); pa_proplist_sets (proplist, PA_PROP_APPLICATION_ID, - "com.canonical.indicators.sound"); + "com.canonical.indicator.sound"); pa_proplist_sets (proplist, PA_PROP_APPLICATION_ICON_NAME, "multimedia-volume-control"); diff --git a/src/settings-manager.vala b/src/settings-manager.vala index 1b99cbc..a2be080 100644 --- a/src/settings-manager.vala +++ b/src/settings-manager.vala @@ -26,7 +26,7 @@ public class SettingsManager : GLib.Object public SettingsManager ( ){ } construct{ - this.settings = new Settings ("com.canonical.indicators.sound"); + this.settings = new Settings ("com.canonical.indicator.sound"); this.settings.changed["blacklisted-media-players"].connect (on_blacklist_event); } diff --git a/src/sound-service-dbus.c b/src/sound-service-dbus.c index b69f081..5650002 100644 --- a/src/sound-service-dbus.c +++ b/src/sound-service-dbus.c @@ -378,7 +378,7 @@ static gboolean sound_service_dbus_blacklist_player (SoundServiceDbus* self, gchar *str; GVariantBuilder builder; - our_settings = g_settings_new ("com.canonical.indicators.sound"); + our_settings = g_settings_new ("com.canonical.indicator.sound"); the_black_list = g_settings_get_value (our_settings, "blacklisted-media-players"); g_variant_iter_init (&iter, the_black_list); @@ -459,7 +459,7 @@ static gboolean sound_service_dbus_is_blacklisted (SoundServiceDbus *self, g_return_val_if_fail (player_name != NULL, FALSE); g_return_val_if_fail (IS_SOUND_SERVICE_DBUS (self), FALSE); - our_settings = g_settings_new ("com.canonical.indicators.sound"); + our_settings = g_settings_new ("com.canonical.indicator.sound"); the_black_list = g_settings_get_value (our_settings, "blacklisted-media-players"); g_variant_iter_init (&iter, the_black_list); diff --git a/src/sound-service.xml b/src/sound-service.xml index 796fa22..cb1d928 100644 --- a/src/sound-service.xml +++ b/src/sound-service.xml @@ -1,6 +1,6 @@ - - + + diff --git a/src/sound-state-manager.c b/src/sound-state-manager.c index c851407..d1c4cca 100644 --- a/src/sound-state-manager.c +++ b/src/sound-state-manager.c @@ -78,7 +78,7 @@ sound_state_manager_init (SoundStateManager* self) priv->notification = NULL; priv->settings_manager = NULL; - priv->settings_manager = g_settings_new("com.canonical.indicators.sound"); + priv->settings_manager = g_settings_new("com.canonical.indicator.sound"); sound_state_manager_notification_init (self); -- cgit v1.2.3