mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-07 23:35:03 +01:00
Show Trigger Patch Selector on selection
This commit is contained in:
parent
a4fd29fa7d
commit
42df6be0fa
2 changed files with 18 additions and 0 deletions
|
|
@ -390,6 +390,8 @@ TriggerPage::selection_changed ()
|
||||||
|
|
||||||
_parameter_box.hide ();
|
_parameter_box.hide ();
|
||||||
|
|
||||||
|
bool hide_patch_selector = true;
|
||||||
|
|
||||||
if (!selection.triggers.empty ()) {
|
if (!selection.triggers.empty ()) {
|
||||||
TriggerSelection ts = selection.triggers;
|
TriggerSelection ts = selection.triggers;
|
||||||
TriggerEntry* entry = *ts.begin ();
|
TriggerEntry* entry = *ts.begin ();
|
||||||
|
|
@ -408,6 +410,20 @@ TriggerPage::selection_changed ()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
_parameter_box.show ();
|
_parameter_box.show ();
|
||||||
|
|
||||||
|
if (boost::dynamic_pointer_cast<MIDITrigger> (trigger)) {
|
||||||
|
/* TODO @ben: only show optionally. checkbox? */
|
||||||
|
hide_patch_selector = false;
|
||||||
|
SessionObject* obj = trigger->box ().owner ();
|
||||||
|
boost::shared_ptr<Stripable> stripable = _session->stripable_by_id (obj->id ());
|
||||||
|
_patch_change_window.reset (boost::dynamic_pointer_cast<Route> (stripable), boost::dynamic_pointer_cast<MIDITrigger> (trigger));
|
||||||
|
_patch_change_window.present ();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hide_patch_selector) {
|
||||||
|
_patch_change_window.hide ();
|
||||||
|
_patch_change_window.clear (); /* drop route/trigger ref */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -38,6 +38,7 @@
|
||||||
#include "midi_region_operations_box.h"
|
#include "midi_region_operations_box.h"
|
||||||
#include "midi_region_properties_box.h"
|
#include "midi_region_properties_box.h"
|
||||||
#include "midi_trigger_properties_box.h"
|
#include "midi_trigger_properties_box.h"
|
||||||
|
#include "patch_change_widget.h"
|
||||||
#include "route_processor_selection.h"
|
#include "route_processor_selection.h"
|
||||||
#include "slot_properties_box.h"
|
#include "slot_properties_box.h"
|
||||||
#include "trigger_clip_picker.h"
|
#include "trigger_clip_picker.h"
|
||||||
|
|
@ -137,6 +138,7 @@ private:
|
||||||
MidiClipEditorBox _midi_trim_box;
|
MidiClipEditorBox _midi_trim_box;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
PatchChangeTriggerWindow _patch_change_window;
|
||||||
RouteProcessorSelection _selection;
|
RouteProcessorSelection _selection;
|
||||||
std::list<TriggerStrip*> _strips;
|
std::list<TriggerStrip*> _strips;
|
||||||
sigc::connection _fast_screen_update_connection;
|
sigc::connection _fast_screen_update_connection;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue