diff --git a/modules/juce_gui_basics/widgets/juce_Slider.cpp b/modules/juce_gui_basics/widgets/juce_Slider.cpp index a9b479c203..5fa6f69cd6 100644 --- a/modules/juce_gui_basics/widgets/juce_Slider.cpp +++ b/modules/juce_gui_basics/widgets/juce_Slider.cpp @@ -1630,6 +1630,7 @@ void Slider::valueChanged() {} void Slider::setPopupMenuEnabled (bool menuEnabled) { pimpl->menuEnabled = menuEnabled; } void Slider::setScrollWheelEnabled (bool enabled) { pimpl->scrollWheelEnabled = enabled; } +bool Slider::isScrollWheelEnabled() const noexcept { return pimpl->scrollWheelEnabled; } bool Slider::isHorizontal() const noexcept { return pimpl->isHorizontal(); } bool Slider::isVertical() const noexcept { return pimpl->isVertical(); } bool Slider::isRotary() const noexcept { return pimpl->isRotary(); } diff --git a/modules/juce_gui_basics/widgets/juce_Slider.h b/modules/juce_gui_basics/widgets/juce_Slider.h index ae31701d91..146f5bd744 100644 --- a/modules/juce_gui_basics/widgets/juce_Slider.h +++ b/modules/juce_gui_basics/widgets/juce_Slider.h @@ -701,6 +701,9 @@ public: */ void setScrollWheelEnabled (bool enabled); + /** Returns true if the scroll wheel can move the slider. */ + bool isScrollWheelEnabled() const noexcept; + /** Returns a number to indicate which thumb is currently being dragged by the mouse. This will return 0 for the main thumb, 1 for the minimum-value thumb, 2 for