aboutsummaryrefslogtreecommitdiff
path: root/src/sound-menu.vala
diff options
context:
space:
mode:
authorLars Uebernickel <lars.uebernickel@canonical.com>2013-09-15 20:31:36 +0200
committerLars Uebernickel <lars.uebernickel@canonical.com>2013-09-15 20:31:36 +0200
commitf0b5cc08bb303864981d8c011faab495aa4e6781 (patch)
tree5879e02301136da8277f7298696a586652c0ac67 /src/sound-menu.vala
parent714775ae8d16509e1c4c57bad36d8a741a48c0e2 (diff)
downloadayatana-indicator-sound-f0b5cc08bb303864981d8c011faab495aa4e6781.tar.gz
ayatana-indicator-sound-f0b5cc08bb303864981d8c011faab495aa4e6781.tar.bz2
ayatana-indicator-sound-f0b5cc08bb303864981d8c011faab495aa4e6781.zip
Don't show the "Mute" menu item in the phone profile
Diffstat (limited to 'src/sound-menu.vala')
-rw-r--r--src/sound-menu.vala5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/sound-menu.vala b/src/sound-menu.vala
index b08db93..251f2f5 100644
--- a/src/sound-menu.vala
+++ b/src/sound-menu.vala
@@ -22,14 +22,15 @@ extern Variant? g_icon_serialize (Icon icon);
class SoundMenu: Object
{
- public SoundMenu (string settings_action) {
+ public SoundMenu (bool show_mute, string settings_action) {
/* A sound menu always has at least two sections: the volume section (this.volume_section)
* at the start of the menu, and the settings section at the end. Between those two,
* it has a dynamic amount of player sections, one for each registered player.
*/
this.volume_section = new Menu ();
- volume_section.append (_("Mute"), "indicator.mute");
+ if (show_mute)
+ volume_section.append (_("Mute"), "indicator.mute");
volume_section.append_item (this.create_slider_menu_item ("indicator.volume", 0.0, 1.0, 0.01,
"audio-volume-low-zero-panel",
"audio-volume-high-panel"));