1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

Merge branch 'pr2532'

This commit is contained in:
tux3 2015-11-08 21:26:19 +01:00
commit f9c324c0f2
No known key found for this signature in database
GPG Key ID: 7E086DD661263264
2 changed files with 10 additions and 7 deletions

View File

@ -69,6 +69,9 @@ AVForm::AVForm() :
bodyUI->playbackSlider->setValue(Settings::getInstance().getOutVolume()); bodyUI->playbackSlider->setValue(Settings::getInstance().getOutVolume());
bodyUI->microphoneSlider->setValue(Settings::getInstance().getInVolume()); bodyUI->microphoneSlider->setValue(Settings::getInstance().getInVolume());
bodyUI->playbackSlider->installEventFilter(this);
bodyUI->microphoneSlider->installEventFilter(this);
for (QComboBox* cb : findChildren<QComboBox*>()) for (QComboBox* cb : findChildren<QComboBox*>())
{ {
cb->installEventFilter(this); cb->installEventFilter(this);
@ -361,7 +364,7 @@ void AVForm::onMicrophoneValueChanged(int value)
bool AVForm::eventFilter(QObject *o, QEvent *e) bool AVForm::eventFilter(QObject *o, QEvent *e)
{ {
if ((e->type() == QEvent::Wheel) && if ((e->type() == QEvent::Wheel) &&
(qobject_cast<QComboBox*>(o) || qobject_cast<QAbstractSpinBox*>(o) )) (qobject_cast<QComboBox*>(o) || qobject_cast<QAbstractSpinBox*>(o) || qobject_cast<QSlider*>(o)))
{ {
e->ignore(); e->ignore();
return true; return true;