diff options
author | David Robillard <d@drobilla.net> | 2012-04-05 00:41:57 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-04-05 00:41:57 +0000 |
commit | 0dc0913b72007da6f9d62213fe0515a9505fc137 (patch) | |
tree | 08ada6ce035aab18bc23e8d8f260cb6ee732be66 /src/gui | |
parent | bdd69d584bae141e9c8550b43adb7a8478434caf (diff) | |
download | ingen-0dc0913b72007da6f9d62213fe0515a9505fc137.tar.gz ingen-0dc0913b72007da6f9d62213fe0515a9505fc137.tar.bz2 ingen-0dc0913b72007da6f9d62213fe0515a9505fc137.zip |
Fix wonky controls when plugin GUI is open (fix #822).
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4141 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/Port.cpp | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/gui/Port.cpp b/src/gui/Port.cpp index 752501a7..3e021840 100644 --- a/src/gui/Port.cpp +++ b/src/gui/Port.cpp @@ -147,15 +147,18 @@ Port::on_value_changed(const Glib::VariantBase& value) const Glib::Variant<double>& fvalue = Glib::VariantBase::cast_dynamic < Glib::Variant<double> >(value); - const float fval = fvalue.get(); - Ingen::Shared::World* const world = _app.world(); - _app.engine()->set_property(model()->path(), - world->uris()->ingen_value, - _app.forge().make(fval)); + + const Raul::Atom atom = _app.forge().make((float)fvalue.get()); + if (atom != model()->value()) { + Ingen::Shared::World* const world = _app.world(); + _app.engine()->set_property(model()->path(), + world->uris()->ingen_value, + atom); + } PatchBox* box = get_patch_box(); if (box) { - box->show_port_status(model().get(), _app.forge().make(fval)); + box->show_port_status(model().get(), atom); } } |