Merge lp:~marcustomlinson/indicator-sound/fix-scroll-wheel-step-sizes into lp:indicator-sound/13.10

Proposed by Marcus Tomlinson
Status: Merged
Approved by: Lars Karlitski
Approved revision: 394
Merged at revision: 393
Proposed branch: lp:~marcustomlinson/indicator-sound/fix-scroll-wheel-step-sizes
Merge into: lp:indicator-sound/13.10
Diff against target: 34 lines (+3/-3)
2 files modified
src/service.vala (+1/-1)
src/sound-menu.vala (+2/-2)
To merge this branch: bzr merge lp:~marcustomlinson/indicator-sound/fix-scroll-wheel-step-sizes
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Lars Karlitski (community) Approve
Matthew Paul Thomas (community) design Needs Information
Charles Kerr (community) Approve
Review via email: mp+191135@code.launchpad.net

Commit message

Modified sensitivity (step size) of the scroll wheel when adjusting volume level to a 5% delta on each wheel click, and matched scroll rates when mouse is over the indicator icon and on the volume slider.

To post a comment you must log in.
Revision history for this message
Charles Kerr (charlesk) wrote :

I agree that there are two bugs here wrt (1) inconsistent scrolling and (2) no smaller steps being available for raising/lowering the volume, but we should fix these by bringing the code into agreement with the existing spec. See https://bugs.launchpad.net/indicator-sound/+bug/1091142 and https://bugs.launchpad.net/indicator-sound/+bug/1226931/comments/2

review: Needs Fixing
392. By Marcus Tomlinson

Increased sensitivity (step size) of the scroll wheel on volume slider when mouse is over the indicator icon, in order to match the scroll rate when the mouse is on the volume slider.

393. By Marcus Tomlinson

Fixed code formatting

Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

I've updated my branch now to simply increase the scroll step size when hovering over the panel icon. Both volume adjustment methods now take 10 clicks of the scroll wheel to span the 0% to 100% range (as per spec).

Revision history for this message
Charles Kerr (charlesk) wrote :

Looks good. Thanks for the quick revision Marcus!

review: Approve
Revision history for this message
Lars Karlitski (larsu) wrote :

This will also change the sensitivity for the volume buttons on the phone. I can't find a design spec for that. Please don't merge this until we've talked to Matthew.

review: Needs Information
Revision history for this message
Matthew Paul Thomas (mpt) wrote :

I haven't specified volume changes on the phone yet at all. <https://wiki.ubuntu.com/Sound#Volume_changes> But some quick testing shows me that Windows Phone has 30 steps from silent to maximum, iOS has 16, and Android has ... 8. Android notwithstanding, I'm leery about reducing the number of steps from 16.7 (?!) to 10 on Ubuntu.

I don't remember why I specced 5% (20 steps) for the -/+/arrow keys on the PC, and 10% for the mouse wheel. Perhaps it was because scrolling a scrollwheel repeatedly is harder than holding down a button. I don't have a mouse wheel here; how many clicks does a typical swipe cause?

review: Needs Information (design)
Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

> I haven't specified volume changes on the phone yet at all.
> <https://wiki.ubuntu.com/Sound#Volume_changes> But some quick testing shows me
> that Windows Phone has 30 steps from silent to maximum, iOS has 16, and
> Android has ... 8. Android notwithstanding, I'm leery about reducing the
> number of steps from 16.7 (?!) to 10 on Ubuntu.

My feeling is that currently the scroll wheel adjusts volume too quickly on the desktop. Comparing Mac OS X, the Ubuntu scroll wheel volume adjustment is about 5 times more sensitive (see my comment on: https://bugs.launchpad.net/indicator-sound/+bug/1226931).

> I don't remember why I specced 5% (20 steps) for the -/+/arrow keys on the PC,
> and 10% for the mouse wheel. Perhaps it was because scrolling a scrollwheel
> repeatedly is harder than holding down a button. I don't have a mouse wheel
> here; how many clicks does a typical swipe cause?

A typical swipe on my mouse has about 7 to 9 clicks.

Revision history for this message
Matthew Paul Thomas (mpt) wrote :

Okay then, how about a step of 5 percent for everything? Mousewheel on the title, mousewheel on the slider, -/+ keys on the slider, Left/Right keys on the slider, keyboard keys on the PC, and hardware keys on the phone.

Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

> Okay then, how about a step of 5 percent for everything?

Sounds good to me.

394. By Marcus Tomlinson

Decreased scroll wheel volume adjustment step size to 5%.

Revision history for this message
Lars Karlitski (larsu) wrote :

Ah cool. Thanks Marcus!

review: Approve
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 'src/service.vala'
2--- src/service.vala 2013-10-09 13:01:14 +0000
3+++ src/service.vala 2013-10-29 16:09:33 +0000
4@@ -87,7 +87,7 @@
5 uint player_action_update_id;
6 Notify.Notification notification;
7
8- const double volume_step_percentage = 0.06;
9+ const double volume_step_percentage = 0.05;
10
11 void activate_scroll_action (SimpleAction action, Variant? param) {
12 int delta = param.get_int32(); /* positive for up, negative for down */
13
14=== modified file 'src/sound-menu.vala'
15--- src/sound-menu.vala 2013-10-28 23:54:31 +0000
16+++ src/sound-menu.vala 2013-10-29 16:09:33 +0000
17@@ -31,7 +31,7 @@
18 this.volume_section = new Menu ();
19 if (show_mute)
20 volume_section.append (_("Mute"), "indicator.mute");
21- volume_section.append_item (this.create_slider_menu_item ("indicator.volume(0)", 0.0, 1.0, 0.01,
22+ volume_section.append_item (this.create_slider_menu_item ("indicator.volume(0)", 0.0, 1.0, 0.005,
23 "audio-volume-low-zero-panel",
24 "audio-volume-high-panel"));
25
26@@ -67,7 +67,7 @@
27 }
28 set {
29 if (value && !this.mic_volume_shown) {
30- var slider = this.create_slider_menu_item ("indicator.mic-volume", 0.0, 1.0, 0.01,
31+ var slider = this.create_slider_menu_item ("indicator.mic-volume", 0.0, 1.0, 0.005,
32 "audio-input-microphone-low-zero-panel",
33 "audio-input-microphone-high-panel");
34 volume_section.append_item (slider);

Subscribers

People subscribed via source and target branches