From a071105a26bd4e7946042c00c30cd7477c13a0b8 Mon Sep 17 00:00:00 2001 From: Leo Franchi Date: Sun, 13 May 2012 20:43:54 -0400 Subject: [PATCH] Add workaround for Qt bug, thanks David Sansome! --- src/TomahawkApp.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/TomahawkApp.cpp b/src/TomahawkApp.cpp index 6243e11b5..1588ff886 100644 --- a/src/TomahawkApp.cpp +++ b/src/TomahawkApp.cpp @@ -290,6 +290,16 @@ TomahawkApp::init() PlaylistUpdaterInterface::registerUpdaterFactory( new XspfUpdaterFactory ); PlaylistUpdaterInterface::registerUpdaterFactory( new SpotifyUpdaterFactory ); + // Following work-around/fix taken from Clementine rev. 13e13ccd9a95 and courtesy of David Sansome + // A bug in Qt means the wheel_scroll_lines setting gets ignored and replaced + // with the default value of 3 in QApplicationPrivate::initialize. + { + QSettings qt_settings(QSettings::UserScope, "Trolltech"); + qt_settings.beginGroup("Qt"); + QApplication::setWheelScrollLines( + qt_settings.value("wheelScrollLines", QApplication::wheelScrollLines()).toInt()); + } + #ifndef ENABLE_HEADLESS // Make sure to init GAM in the gui thread GlobalActionManager::instance();