do not stupidly try to save punch/loop/session ranges during clear_ranges op

This commit is contained in:
Paul Davis 2014-09-17 09:38:17 -04:00
parent 5c087b5716
commit d7f37c9bab

View file

@ -2142,15 +2142,7 @@ Editor::clear_ranges ()
_session->begin_reversible_command (_("clear ranges"));
XMLNode &before = _session->locations()->get_state();
Location * looploc = _session->locations()->auto_loop_location();
Location * punchloc = _session->locations()->auto_punch_location();
Location * sessionloc = _session->locations()->session_range_location();
_session->locations()->clear_ranges ();
// re-add these
if (looploc) _session->locations()->add (looploc);
if (punchloc) _session->locations()->add (punchloc);
if (sessionloc) _session->locations()->add (sessionloc);
XMLNode &after = _session->locations()->get_state();
_session->add_command(new MementoCommand<Locations>(*(_session->locations()), &before, &after));