on xenial help sign in
On the PC platform (as opposed to running on $devices), use the "mute" action instead of silent mode
f7a99a5Lukáš Tinkl
qml/Components/VolumeControl.qml+2−3
@@ -17,6 +17,7 @@
17import QtQuick 2.4
17import QtQuick 2.4
18import QMenuModel 0.1 as QMenuModel
18import QMenuModel 0.1 as QMenuModel
19import GlobalShortcut 1.0
19import GlobalShortcut 1.0
20+import Unity.Platform 1.0
20
21
21Item {
22Item {
22 id: root
23 id: root
@@ -27,8 +28,6 @@ Item {
27 readonly property int stepUp: 1
28 readonly property int stepUp: 1
28 readonly property int stepDown: -1
29 readonly property int stepDown: -1
29
30
30− property var indicators // passed from Shell.qml
31−
32 GlobalShortcut {
31 GlobalShortcut {
33 id: muteShortcut
32 id: muteShortcut
34 shortcut: Qt.Key_VolumeMute
33 shortcut: Qt.Key_VolumeMute
@@ -42,7 +41,7 @@ Item {
42 objectPath: "/com/canonical/indicator/sound"
41 objectPath: "/com/canonical/indicator/sound"
43
42
44 property variant actionObject: action("volume")
43 property variant actionObject: action("volume")
45− property variant muteActionObject: indicators.indicatorsModel.profile === "desktop" ? action("mute") : action("silent-mode")
44+ property variant muteActionObject: Platform.isPC ? action("mute") : action("silent-mode")
46 }
45 }
47
46
48 function volumeUp() {
47 function volumeUp() {
qml/Shell.qml−1
@@ -177,7 +177,6 @@ StyledItem {
177
177
178 VolumeControl {
178 VolumeControl {
179 id: volumeControl
179 id: volumeControl
180− indicators: panel.indicators
181 }
180 }
182
181
183 DashCommunicator {
182 DashCommunicator {