diff --git a/gtk2_ardour/cuebox_ui.cc b/gtk2_ardour/cuebox_ui.cc index b51d250766..1c30538af8 100644 --- a/gtk2_ardour/cuebox_ui.cc +++ b/gtk2_ardour/cuebox_ui.cc @@ -286,6 +286,7 @@ CueBoxUI::context_menu (uint64_t idx) MenuList& litems = launch_menu->items (); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::OneShot), sigc::bind (sigc::mem_fun (*this, &CueBoxUI::set_all_launch_style), Trigger::OneShot, idx))); + litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::ReTrigger), sigc::bind (sigc::mem_fun (*this, &CueBoxUI::set_all_launch_style), Trigger::ReTrigger, idx))); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::Gate), sigc::bind (sigc::mem_fun (*this, &CueBoxUI::set_all_launch_style), Trigger::Gate, idx))); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::Toggle), sigc::bind (sigc::mem_fun (*this, &CueBoxUI::set_all_launch_style), Trigger::Toggle, idx))); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::Repeat), sigc::bind (sigc::mem_fun (*this, &CueBoxUI::set_all_launch_style), Trigger::Repeat, idx))); diff --git a/gtk2_ardour/slot_properties_box.cc b/gtk2_ardour/slot_properties_box.cc index 405cde25c6..46710d5b19 100644 --- a/gtk2_ardour/slot_properties_box.cc +++ b/gtk2_ardour/slot_properties_box.cc @@ -165,6 +165,7 @@ SlotPropertyTable::SlotPropertyTable () _launch_style_button.set_name("FollowAction"); _launch_style_button.set_sizing_text (longest_launch); _launch_style_button.AddMenuElem (MenuElem (launch_style_to_string (Trigger::OneShot), sigc::bind (sigc::mem_fun (*this, &SlotPropertyTable::set_launch_style), Trigger::OneShot))); + _launch_style_button.AddMenuElem (MenuElem (launch_style_to_string (Trigger::ReTrigger), sigc::bind (sigc::mem_fun (*this, &SlotPropertyTable::set_launch_style), Trigger::ReTrigger))); _launch_style_button.AddMenuElem (MenuElem (launch_style_to_string (Trigger::Gate), sigc::bind (sigc::mem_fun (*this, &SlotPropertyTable::set_launch_style), Trigger::Gate))); _launch_style_button.AddMenuElem (MenuElem (launch_style_to_string (Trigger::Toggle), sigc::bind (sigc::mem_fun (*this, &SlotPropertyTable::set_launch_style), Trigger::Toggle))); _launch_style_button.AddMenuElem (MenuElem (launch_style_to_string (Trigger::Repeat), sigc::bind (sigc::mem_fun (*this, &SlotPropertyTable::set_launch_style), Trigger::Repeat))); diff --git a/gtk2_ardour/trigger_master.cc b/gtk2_ardour/trigger_master.cc index b861aa949a..ca8dd57f79 100644 --- a/gtk2_ardour/trigger_master.cc +++ b/gtk2_ardour/trigger_master.cc @@ -363,6 +363,7 @@ TriggerMaster::context_menu () MenuList& litems = launch_menu->items (); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::OneShot), sigc::bind (sigc::mem_fun (*this, &TriggerMaster::set_all_launch_style), Trigger::OneShot))); + litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::ReTrigger), sigc::bind (sigc::mem_fun (*this, &TriggerMaster::set_all_launch_style), Trigger::ReTrigger))); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::Gate), sigc::bind (sigc::mem_fun (*this, &TriggerMaster::set_all_launch_style), Trigger::Gate))); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::Toggle), sigc::bind (sigc::mem_fun (*this, &TriggerMaster::set_all_launch_style), Trigger::Toggle))); litems.push_back (MenuElem (TriggerUI::launch_style_to_string(Trigger::Repeat), sigc::bind (sigc::mem_fun (*this, &TriggerMaster::set_all_launch_style), Trigger::Repeat))); diff --git a/gtk2_ardour/trigger_ui.cc b/gtk2_ardour/trigger_ui.cc index 589b93a695..2d546a9780 100644 --- a/gtk2_ardour/trigger_ui.cc +++ b/gtk2_ardour/trigger_ui.cc @@ -92,6 +92,7 @@ TriggerUI::TriggerUI () } launch_strings.push_back (launch_style_to_string (Trigger::OneShot)); + launch_strings.push_back (launch_style_to_string (Trigger::ReTrigger)); launch_strings.push_back (launch_style_to_string (Trigger::Gate)); launch_strings.push_back (launch_style_to_string (Trigger::Toggle)); launch_strings.push_back (launch_style_to_string (Trigger::Repeat)); @@ -451,6 +452,10 @@ TriggerUI::launch_context_menu () if (trigger ()->launch_style () == Trigger::OneShot) { dynamic_cast (&litems.back ())->set_active (true); } + litems.push_back (RadioMenuElem (lagroup, TriggerUI::launch_style_to_string(Trigger::ReTrigger), sigc::bind(sigc::mem_fun (*this, &TriggerUI::set_launch_style), Trigger::ReTrigger))); + if (trigger ()->launch_style () == Trigger::ReTrigger) { + dynamic_cast (&litems.back ())->set_active (true); + } litems.push_back (RadioMenuElem (lagroup, TriggerUI::launch_style_to_string(Trigger::Gate), sigc::bind(sigc::mem_fun (*this, &TriggerUI::set_launch_style), Trigger::Gate))); if (trigger ()->launch_style () == Trigger::Gate) { dynamic_cast (&litems.back ())->set_active (true); @@ -694,6 +699,8 @@ TriggerUI::launch_style_to_string (Trigger::LaunchStyle ls) switch (ls) { case Trigger::OneShot: return _("One Shot"); + case Trigger::ReTrigger: + return _("Retrigger"); case Trigger::Gate: return _("Gate"); case Trigger::Toggle: diff --git a/gtk2_ardour/triggerbox_ui.cc b/gtk2_ardour/triggerbox_ui.cc index 42666d9e11..0683e0963f 100644 --- a/gtk2_ardour/triggerbox_ui.cc +++ b/gtk2_ardour/triggerbox_ui.cc @@ -325,6 +325,14 @@ TriggerEntry::draw_launch_icon (Cairo::RefPtr context, float sz, context->line_to (margin, margin); context->stroke (); break; + /* XXX ben this needs a new icon */ + case Trigger::ReTrigger: + context->move_to (margin, margin); + context->rel_line_to (0, size); + context->rel_line_to (size, -size/2); + context->line_to (margin, margin); + context->stroke (); + break; case Trigger::Gate: //diamond shape context->move_to ( margin+size/2, margin ); context->rel_line_to ( size/2, size/2);