Merge lp:~larsu/unity8/lp1219057 into lp:unity8

Proposed by Lars Karlitski
Status: Merged
Approved by: Michał Sawicz
Approved revision: 303
Merged at revision: 327
Proposed branch: lp:~larsu/unity8/lp1219057
Merge into: lp:unity8
Diff against target: 47 lines (+6/-21)
1 file modified
Components/VolumeControl.qml (+6/-21)
To merge this branch: bzr merge lp:~larsu/unity8/lp1219057
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Michał Sawicz Approve
Review via email: mp+184622@code.launchpad.net

Commit message

VolumeControl: use action of the new indicator

indicator-sound recently gained an action to increase and decrease the volume. This patch makes use of that to get rid of a bus round trip (to get the current volume) and a race (when the volume gets set between fetching the current volume and setting the new volume).

Description of the change

VolumeControl: use action of the new indicator

indicator-sound recently gained an action to increase and decrease the volume. This patch makes use of that to get rid of a bus round trip (to get the current volume) and a race (when the volume gets set between fetching the current volume and setting the new volume).

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Continuous integration, rev:303
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https://code.launchpad.net/~larsu/unity8/lp1219057/+merge/184622/+edit-commit-message

http://jenkins.qa.ubuntu.com/job/unity8-ci/951/
Executed test runs:
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-saucy/3194
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-touch/752
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity-phablet-qmluitests-saucy/1618
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-ci/952
        deb: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-ci/952/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-i386-ci/951
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3200
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3200/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-saucy/2687
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/754
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/754/artifact/work/output/*zip*/output.zip
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-maguro/621
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-mako/632

Click here to trigger a rebuild:
http://s-jenkins:8080/job/unity8-ci/951/rebuild

review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Michał Sawicz (saviq) wrote :

Yup, this works.

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Autolanding.
More details in the following jenkins job:
http://jenkins.qa.ubuntu.com/job/unity8-autolanding/444/
Executed test runs:
    SUCCESS: http://s-jenkins:8080/job/generic-cleanup-mbs/2222
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-saucy/3484
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-touch/1012
    FAILURE: http://jenkins.qa.ubuntu.com/job/unity-phablet-qmluitests-saucy/1716/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-amd64-autolanding/27
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-autolanding/445
        deb: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-autolanding/445/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-i386-autolanding/446
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3496
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3496/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-saucy/2950
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1014
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1014/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-maguro/851
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-mako/863

review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Autolanding.
More details in the following jenkins job:
http://jenkins.qa.ubuntu.com/job/unity8-autolanding/446/
Executed test runs:
    SUCCESS: http://s-jenkins:8080/job/generic-cleanup-mbs/2234
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-saucy/3499
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-touch/1027
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity-phablet-qmluitests-saucy/1720
    FAILURE: http://jenkins.qa.ubuntu.com/job/unity8-saucy-amd64-autolanding/30/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-autolanding/448
        deb: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-autolanding/448/artifact/work/output/*zip*/output.zip
    FAILURE: http://jenkins.qa.ubuntu.com/job/unity8-saucy-i386-autolanding/449/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3511
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3511/artifact/work/output/*zip*/output.zip
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-saucy/2963
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1029
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1029/artifact/work/output/*zip*/output.zip
    UNSTABLE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-maguro/862
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-mako/874

review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Autolanding.
More details in the following jenkins job:
http://jenkins.qa.ubuntu.com/job/unity8-autolanding/448/
Executed test runs:
    FAILURE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-saucy/3523/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-touch/1051
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity-phablet-qmluitests-saucy/1731
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-amd64-autolanding/34
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-autolanding/452
        deb: http://jenkins.qa.ubuntu.com/job/unity8-saucy-armhf-autolanding/452/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/unity8-saucy-i386-autolanding/453
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3535
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-i386/3535/artifact/work/output/*zip*/output.zip
    FAILURE: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-saucy/2985/console
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1053
        deb: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-builder-saucy-armhf/1053/artifact/work/output/*zip*/output.zip
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-maguro/881
    SUCCESS: http://jenkins.qa.ubuntu.com/job/generic-mediumtests-runner-mako/893

review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Components/VolumeControl.qml'
2--- Components/VolumeControl.qml 2013-06-05 22:03:08 +0000
3+++ Components/VolumeControl.qml 2013-09-09 17:00:47 +0000
4@@ -21,37 +21,22 @@
5 id: root
6 objectName: "volumeControl"
7 visible: false
8- property int volume
9
10 QDBusActionGroup {
11 id: actionGroup
12 busType: 1
13- busName: "com.canonical.settings.sound"
14- objectPath: "/com/canonical/settings/sound"
15-
16- property variant actionObject: action("volume")
17- property variant serverVolume: actionObject.valid ? actionObject.state: 0
18- }
19-
20- Binding {
21- target: root
22- property: "volume"
23- value: actionGroup.serverVolume * 100
24- }
25-
26- onVolumeChanged: {
27- if (actionGroup.serverVolume != volume) {
28- var targetVolume = Math.min(1, Math.max(0, volume / 100));
29- actionGroup.actionObject.updateState(targetVolume);
30- }
31+ busName: "com.canonical.indicator.sound"
32+ objectPath: "/com/canonical/indicator/sound"
33+
34+ property variant actionObject: action("scroll")
35 }
36
37 function volumeUp() {
38- actionGroup.actionObject.updateState(Math.min(1, volume/100 + 0.10));
39+ actionGroup.actionObject.activate(1);
40 }
41
42 function volumeDown() {
43- actionGroup.actionObject.updateState(Math.max(0, volume/100 - 0.10));
44+ actionGroup.actionObject.activate(-1);
45 }
46
47 Component.onCompleted: actionGroup.start()

Subscribers

People subscribed via source and target branches