Contrary to what is documented '+' and KEY_UP did not the same thing. The behavior was as follows:
W | + increase volume by 1% w | KEY_UP increase volume by 2% X | - decrease volume by 1% x | KEY_DOWN decrease volume by 2%
Now all of them change the volume by only 1%.
Signed-off-by: Simon Hengel simon.hengel@gmx.net
diff --git a/alsamixer/alsamixer.c b/alsamixer/alsamixer.c index 414033e..554326f 100644 --- a/alsamixer/alsamixer.c +++ b/alsamixer/alsamixer.c @@ -1916,15 +1916,6 @@ mixer_set_delta(int delta) mixer_volume_delta[grp] = delta; }
-static void -mixer_add_delta(int delta) -{ - int grp; - - for (grp = 0; grp < 2; grp++) - mixer_volume_delta[grp] += delta; -} - static int mixer_iteration (void) { @@ -2172,22 +2163,16 @@ mixer_iteration (void) mixer_set_delta(-100); break; case '+': - mixer_set_delta(1); - break; - case '-': - mixer_set_delta(-1); - break; case 'w': + case 'W': case KEY_UP: mixer_set_delta(1); - case 'W': - mixer_add_delta(1); break; + case '-': case 'x': + case 'X': case KEY_DOWN: mixer_set_delta(-1); - case 'X': - mixer_add_delta(-1); break; case '0': case '1':