on xenial help sign in
hide the volume notification iff the indicator bar is expanded and the current indicator is sound
commitba738ae2e4ee1da253ccfaa791be2fe152bdcfb3 authorLukáš Tinkl <lukas.tinkl@canonical.com> dateThu 20 Aug 2015, 16:07 (11 years ago) parentd1c8152
3 files changed+8−7
qml/Components/VolumeControl.qml+6−7 qml/Panel/IndicatorsBar.qml+1 qml/Panel/IndicatorsMenu.qml+1
qml/Components/VolumeControl.qml+6−7
@@ -47,13 +47,12 @@ Item {
4747 }
4848
4949 Connections {
50− target: indicators
51− onFullyOpenedChanged: { // disallow the volume notification when using the slider
52− if (indicators.fullyOpened) {
53− actionGroup.indicatorsAction.updateState(true);
54− } else {
55− actionGroup.indicatorsAction.updateState(false);
56− }
50+ target: indicators // disallow the volume notification when using the slider, lpbug#1484126
51+ onFullyOpenedChanged: {
52+ actionGroup.indicatorsAction.updateState(indicators.fullyOpened && indicators.currentIndicator === "indicator-sound");
53+ }
54+ onCurrentIndicatorChanged: {
55+ actionGroup.indicatorsAction.updateState(indicators.fullyOpened && indicators.currentIndicator === "indicator-sound");
5756 }
5857 }
5958
qml/Panel/IndicatorsBar.qml+1
@@ -28,6 +28,7 @@ Item {
2828 property alias overFlowWidth: row.overFlowWidth
2929 readonly property alias currentItemIndex: row.currentItemIndex
3030 property real lateralPosition: -1
31+ readonly property string currentIndicator: row.currentItem ? row.currentItem.identifier : ""
3132
3233 function selectItemAt(lateralPosition) {
3334 if (!expanded) {
qml/Panel/IndicatorsMenu.qml+1
@@ -27,6 +27,7 @@ Showable {
2727 property alias hideDragHandle: __hideDragHandle
2828 property alias overFlowWidth: bar.overFlowWidth
2929 property alias verticalVelocityThreshold: yVelocityCalculator.velocityThreshold
30+ property alias currentIndicator: bar.currentIndicator
3031 property int minimizedPanelHeight: units.gu(3)
3132 property int expandedPanelHeight: units.gu(7)
3233 property real openedHeight: units.gu(71)