X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/937013e0fd914d4c42f9f5ec98da665986b93dfa..d1263a3992c1ccf03c98d99bbfce9849196caf6f:/src/gtk/slider.cpp diff --git a/src/gtk/slider.cpp b/src/gtk/slider.cpp index 6440262ee4..f14ae6394a 100644 --- a/src/gtk/slider.cpp +++ b/src/gtk/slider.cpp @@ -357,6 +357,8 @@ void wxSlider::GTKSetValue(int value) void wxSlider::SetRange( int minValue, int maxValue ) { m_blockScrollEvent = true; + if (minValue == maxValue) + maxValue++; gtk_range_set_range(GTK_RANGE (m_widget), minValue, maxValue); gtk_range_set_increments(GTK_RANGE (m_widget), 1, (maxValue - minValue + 9) / 10); m_blockScrollEvent = false;