Index: ardour2/gtk2_ardour/editor_markers.cc =================================================================== --- ardour2/gtk2_ardour/editor_markers.cc (revision 1249) +++ ardour2/gtk2_ardour/editor_markers.cc (working copy) @@ -481,6 +481,7 @@ items.push_back (MenuElem (_("Locate to Range Mark"), mem_fun(*this, &Editor::marker_menu_set_playhead))); items.push_back (MenuElem (_("Play from Range Mark"), mem_fun(*this, &Editor::marker_menu_play_from))); + items.push_back (MenuElem (_("Play Range"), mem_fun(*this, &Editor::marker_menu_play_range))); items.push_back (MenuElem (_("Loop Range"), mem_fun(*this, &Editor::marker_menu_loop_range))); items.push_back (MenuElem (_("Set Range Mark from Playhead"), mem_fun(*this, &Editor::marker_menu_set_from_playhead))); items.push_back (MenuElem (_("Set Range from Range Selection"), mem_fun(*this, &Editor::marker_menu_set_from_selection))); @@ -726,7 +727,33 @@ } } + void +Editor::marker_menu_play_range () +{ + Marker* marker; + + if ((marker = reinterpret_cast (marker_menu_item->get_data ("marker"))) == 0) { + fatal << _("programming error: marker canvas item has no marker object pointer!") << endmsg; + /*NOTREACHED*/ + } + + Location* l; + bool is_start; + + if ((l = find_location_from_marker (marker, is_start)) != 0) { + + if (l->is_mark()) { + session->request_locate (l->start(), true); + } + else { + session->request_bounded_roll (l->start(), l->end()); + + } + } +} + +void Editor::marker_menu_loop_range () { Marker* marker; Index: ardour2/gtk2_ardour/editor.h =================================================================== --- ardour2/gtk2_ardour/editor.h (revision 1249) +++ ardour2/gtk2_ardour/editor.h (working copy) @@ -1205,6 +1205,7 @@ void marker_menu_select_all_selectables_using_range (); void marker_menu_separate_regions_using_location (); void marker_menu_play_from (); + void marker_menu_play_range (); void marker_menu_set_playhead (); void marker_menu_set_from_playhead (); void marker_menu_set_from_selection (); Index: ardour2/libs/ardour/session_transport.cc =================================================================== --- ardour2/libs/ardour/session_transport.cc (revision 1249) +++ ardour2/libs/ardour/session_transport.cc (working copy) @@ -1150,7 +1150,7 @@ Session::request_bounded_roll (nframes_t start, nframes_t end) { request_stop (); - Event *ev = new Event (Event::StopOnce, Event::Replace, Event::Immediate, end, 0.0); + Event *ev = new Event (Event::StopOnce, Event::Replace, end, Event::Immediate, 0.0); queue_event (ev); request_locate (start, true); }