This commit fixes the issue of being able to scroll through the mixer with the mouse wheel without modifying the volume slider. This functionality can be temporarily restored by holding a click on the volume meter.
24 lines
397 B
C++
24 lines
397 B
C++
#pragma once
|
|
|
|
#include <QSlider>
|
|
#include <QInputEvent>
|
|
#include <QtCore/QObject>
|
|
|
|
|
|
|
|
|
|
class SliderIgnoreScroll : public QSlider {
|
|
Q_OBJECT
|
|
|
|
public:
|
|
SliderIgnoreScroll(QWidget *parent = nullptr);
|
|
SliderIgnoreScroll(Qt::Orientation orientation, QWidget *parent = nullptr);
|
|
|
|
protected:
|
|
|
|
virtual void wheelEvent(QWheelEvent *event) override;
|
|
virtual void leaveEvent(QEvent *event) override;
|
|
};
|
|
|
|
|