RegionFX: replay control automation (2/2)
Trigger GUI updates when region-fx are automated
This commit is contained in:
parent
79ff99ba15
commit
002eabc01f
@ -51,6 +51,7 @@
|
|||||||
#include "new_plugin_preset_dialog.h"
|
#include "new_plugin_preset_dialog.h"
|
||||||
#include "region_editor.h"
|
#include "region_editor.h"
|
||||||
#include "region_view.h"
|
#include "region_view.h"
|
||||||
|
#include "timers.h"
|
||||||
#include "plugin_selector.h"
|
#include "plugin_selector.h"
|
||||||
#include "plugin_window_proxy.h"
|
#include "plugin_window_proxy.h"
|
||||||
#include "public_editor.h"
|
#include "public_editor.h"
|
||||||
@ -552,6 +553,8 @@ RegionEditor::RegionFxBox::RegionFxBox (std::shared_ptr<ARDOUR::Region> r)
|
|||||||
|
|
||||||
_display.signal_key_press_event ().connect (sigc::mem_fun (*this, &RegionFxBox::on_key_press), false);
|
_display.signal_key_press_event ().connect (sigc::mem_fun (*this, &RegionFxBox::on_key_press), false);
|
||||||
|
|
||||||
|
screen_update_connection = Timers::super_rapid_connect (sigc::mem_fun (*this, &RegionFxBox::update_controls));
|
||||||
|
|
||||||
_scroller.show ();
|
_scroller.show ();
|
||||||
_display.show ();
|
_display.show ();
|
||||||
|
|
||||||
@ -745,6 +748,19 @@ RegionEditor::RegionFxBox::on_key_press (GdkEventKey* ev)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
RegionEditor::RegionFxBox::update_controls ()
|
||||||
|
{
|
||||||
|
for (auto const& i : _display.children ()) {
|
||||||
|
std::shared_ptr<ARDOUR::RegionFxPlugin> rfx = i->region_fx_plugin ();
|
||||||
|
PluginWindowProxy* pwp = dynamic_cast<PluginWindowProxy*> (rfx->window_proxy ());
|
||||||
|
if (!pwp || !pwp->get (false) || !pwp->get (false)->is_mapped ()) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
rfx->maybe_emit_changed_signals ();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
RegionEditor::RegionFxBox::clear_automation (std::weak_ptr<ARDOUR::RegionFxPlugin> wfx)
|
RegionEditor::RegionFxBox::clear_automation (std::weak_ptr<ARDOUR::RegionFxPlugin> wfx)
|
||||||
{
|
{
|
||||||
|
@ -109,6 +109,7 @@ private:
|
|||||||
void notify_plugin_load_fail (uint32_t cnt = 1);
|
void notify_plugin_load_fail (uint32_t cnt = 1);
|
||||||
bool on_key_press (GdkEventKey*);
|
bool on_key_press (GdkEventKey*);
|
||||||
void clear_automation (std::weak_ptr<ARDOUR::RegionFxPlugin>);
|
void clear_automation (std::weak_ptr<ARDOUR::RegionFxPlugin>);
|
||||||
|
void update_controls ();
|
||||||
|
|
||||||
/* PluginInterestedObject */
|
/* PluginInterestedObject */
|
||||||
bool use_plugins (SelectedPlugins const&);
|
bool use_plugins (SelectedPlugins const&);
|
||||||
@ -130,6 +131,8 @@ private:
|
|||||||
Gtk::EventBox _base;
|
Gtk::EventBox _base;
|
||||||
bool _no_redisplay;
|
bool _no_redisplay;
|
||||||
int _placement;
|
int _placement;
|
||||||
|
|
||||||
|
sigc::connection screen_update_connection;
|
||||||
};
|
};
|
||||||
|
|
||||||
std::shared_ptr<ARDOUR::Region> _region;
|
std::shared_ptr<ARDOUR::Region> _region;
|
||||||
|
Loading…
Reference in New Issue
Block a user