From 7415b7f4bdee1b7c822e75bdeb684cb1269ad911 Mon Sep 17 00:00:00 2001 From: David Sansome Date: Wed, 31 Mar 2010 23:45:52 +0000 Subject: [PATCH] Made mouse wheel events on both the tray icon and the volume widget change the volume by a smaller amount. Fixes issue #145 --- src/mainwindow.cpp | 2 +- src/sliderwidget.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index e6a369600..199f216c1 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -479,7 +479,7 @@ void MainWindow::LibraryDoubleClick(const QModelIndex& index) { } void MainWindow::VolumeWheelEvent(int delta) { - ui_.volume->setValue(ui_.volume->value() + delta / 20); + ui_.volume->setValue(ui_.volume->value() + delta / 30); } void MainWindow::TrayClicked(QSystemTrayIcon::ActivationReason reason) { diff --git a/src/sliderwidget.cpp b/src/sliderwidget.cpp index 372237a5f..1ca80ad90 100644 --- a/src/sliderwidget.cpp +++ b/src/sliderwidget.cpp @@ -315,7 +315,7 @@ Amarok::VolumeSlider::slideEvent( QMouseEvent *e ) void Amarok::VolumeSlider::wheelEvent( QWheelEvent *e ) { - const uint step = e->delta() / 10; + const uint step = e->delta() / 30; QSlider::setValue( QSlider::value() + step ); emit sliderReleased( value() );