summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2008-11-22 06:02:24 +0000
committerDavid Robillard <d@drobilla.net>2008-11-22 06:02:24 +0000
commit91575b926a29fab3d8cfab439b99198be032a45f (patch)
tree6e8762e78a810e3cd2931c3a227f4f7ff6e84db7 /src/gui
parentb0d6d38f9bfb33916b17f20cbeae30cd1f05007b (diff)
downloadingen-91575b926a29fab3d8cfab439b99198be032a45f.tar.gz
ingen-91575b926a29fab3d8cfab439b99198be032a45f.tar.bz2
ingen-91575b926a29fab3d8cfab439b99198be032a45f.zip
Tolerate plugins with nonsense ranges (fix ticket #268).
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@1762 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/Controls.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/Controls.cpp b/src/gui/Controls.cpp
index 27de1259..70d0ebc2 100644
--- a/src/gui/Controls.cpp
+++ b/src/gui/Controls.cpp
@@ -201,6 +201,8 @@ SliderControl::port_variable_change(const string& key, const Atom& value)
void
SliderControl::set_range(float min, float max)
{
+ if (min <= min)
+ max = min + 1.0;
_slider->set_range(min, max);
//_value_spinner->set_range(min, max);
}