Keep track of recently touched Controllable
This commit is contained in:
parent
b3f019b8b7
commit
7e74f9eb1e
@ -1154,6 +1154,7 @@ public:
|
||||
void add_controllable (boost::shared_ptr<PBD::Controllable>);
|
||||
|
||||
boost::shared_ptr<PBD::Controllable> solo_cut_control() const;
|
||||
boost::shared_ptr<PBD::Controllable> recently_touched_controllable () const;
|
||||
|
||||
SessionConfiguration config;
|
||||
|
||||
@ -2097,6 +2098,9 @@ private:
|
||||
|
||||
boost::shared_ptr<PBD::Controllable> _solo_cut_control;
|
||||
|
||||
void controllable_touched (boost::weak_ptr<PBD::Controllable>);
|
||||
boost::weak_ptr<PBD::Controllable> _recently_touched_controllable;
|
||||
|
||||
void reset_native_file_format();
|
||||
bool first_file_data_format_reset;
|
||||
bool first_file_header_format_reset;
|
||||
|
@ -284,6 +284,8 @@ AutomationControl::start_touch (double when)
|
||||
return;
|
||||
}
|
||||
|
||||
ControlTouched (boost::dynamic_pointer_cast<PBD::Controllable>(shared_from_this())); /* EMIT SIGNAL */
|
||||
|
||||
if (alist()->automation_state() & (Touch | Latch)) {
|
||||
/* subtle. aligns the user value with the playback and
|
||||
* use take actual value (incl masters).
|
||||
|
@ -462,6 +462,8 @@ Session::Session (AudioEngine &eng,
|
||||
LatentSend::ChangedLatency.connect_same_thread (*this, boost::bind (&Session::send_latency_compensation_change, this));
|
||||
Latent::DisableSwitchChanged.connect_same_thread (*this, boost::bind (&Session::queue_latency_recompute, this));
|
||||
|
||||
Controllable::ControlTouched.connect_same_thread (*this, boost::bind (&Session::controllable_touched, this, _1));
|
||||
|
||||
emit_thread_start ();
|
||||
auto_connect_thread_start ();
|
||||
|
||||
@ -6850,6 +6852,18 @@ Session::notify_presentation_info_change ()
|
||||
reassign_track_numbers();
|
||||
}
|
||||
|
||||
void
|
||||
Session::controllable_touched (boost::weak_ptr<PBD::Controllable> c)
|
||||
{
|
||||
_recently_touched_controllable = c;
|
||||
}
|
||||
|
||||
boost::shared_ptr<PBD::Controllable>
|
||||
Session::recently_touched_controllable () const
|
||||
{
|
||||
return _recently_touched_controllable.lock ();
|
||||
}
|
||||
|
||||
bool
|
||||
Session::operation_in_progress (GQuark op) const
|
||||
{
|
||||
|
@ -35,6 +35,7 @@ using namespace std;
|
||||
PBD::Signal1<bool, boost::weak_ptr<PBD::Controllable> > Controllable::StartLearning;
|
||||
PBD::Signal1<void, boost::weak_ptr<PBD::Controllable> > Controllable::StopLearning;
|
||||
PBD::Signal1<void, boost::weak_ptr<PBD::Controllable> > Controllable::GUIFocusChanged;
|
||||
PBD::Signal1<void, boost::weak_ptr<PBD::Controllable> > Controllable::ControlTouched;
|
||||
|
||||
Glib::Threads::RWLock Controllable::registry_lock;
|
||||
Controllable::Controllables Controllable::registry;
|
||||
|
@ -141,6 +141,7 @@ public:
|
||||
static PBD::Signal1<void, boost::weak_ptr<PBD::Controllable> > StopLearning;
|
||||
|
||||
static PBD::Signal1<void, boost::weak_ptr<PBD::Controllable> > GUIFocusChanged;
|
||||
static PBD::Signal1<void, boost::weak_ptr<PBD::Controllable> > ControlTouched;
|
||||
|
||||
PBD::Signal2<void,bool,PBD::Controllable::GroupControlDisposition> Changed;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user