r316@gandalf: fugalh | 2006-08-11 17:06:48 -0600
[ardour.git] / gtk2_ardour / editor_markers.cc
index ccc1415888449f1c92bfac39f810de0106c48f25..40f00c2e109be2e24c8621f4badc5a0dec96e8f4 100644 (file)
@@ -294,7 +294,7 @@ Editor::mouse_add_new_marker (jack_nframes_t where)
                 XMLNode &before = session->locations()->get_state();
                session->locations()->add (location, true);
                 XMLNode &after = session->locations()->get_state();
-               session->add_command (new MementoCommand<Locations>(*(session->locations()), before, after));
+               session->add_command (new MementoCommand<Locations>(*(session->locations()), &before, &after));
                session->commit_reversible_command ();
        }
 }
@@ -334,7 +334,7 @@ Editor::really_remove_marker (Location* loc)
        XMLNode &before = session->locations()->get_state();
        session->locations()->remove (loc);
        XMLNode &after = session->locations()->get_state();
-       session->add_command (new MementoCommand<Locations>(*(session->locations()), before, after));
+       session->add_command (new MementoCommand<Locations>(*(session->locations()), &before, &after));
        session->commit_reversible_command ();
        return FALSE;
 }
@@ -847,7 +847,7 @@ Editor::marker_menu_rename ()
        loc->set_name (txt);
        
         XMLNode &after = session->locations()->get_state();
-       session->add_command (new MementoCommand<Locations>(*(session->locations()), before, after));
+       session->add_command (new MementoCommand<Locations>(*(session->locations()), &before, &after));
        commit_reversible_command ();
 }
 
@@ -876,14 +876,14 @@ Editor::new_transport_marker_menu_set_loop ()
                session->locations()->add (loc, true);
                session->set_auto_loop_location (loc);
                 XMLNode &after = session->locations()->get_state();
-               session->add_command (new MementoCommand<Locations>(*(session->locations()), before, after));
+               session->add_command (new MementoCommand<Locations>(*(session->locations()), &before, &after));
        }
        else {
                 XMLNode &before = tll->get_state();
                tll->set_hidden (false, this);
                tll->set (temp_location->start(), temp_location->end());
                 XMLNode &after = tll->get_state();
-                session->add_command (new MementoCommand<Location>(*tll, before, after));
+                session->add_command (new MementoCommand<Location>(*tll, &before, &after));
        }
        
        commit_reversible_command ();
@@ -904,13 +904,13 @@ Editor::new_transport_marker_menu_set_punch ()
                session->locations()->add (tpl, true);
                session->set_auto_punch_location (tpl);
                 XMLNode &after = session->locations()->get_state();
-               session->add_command (new MementoCommand<Locations>(*(session->locations()), before, after));
+               session->add_command (new MementoCommand<Locations>(*(session->locations()), &before, &after));
        } else {
                 XMLNode &before = tpl->get_state();
                tpl->set_hidden(false, this);
                tpl->set(temp_location->start(), temp_location->end());
                 XMLNode &after = tpl->get_state();
-                session->add_command (new MementoCommand<Location>(*tpl, before, after));
+                session->add_command (new MementoCommand<Location>(*tpl, &before, &after));
        }
        
        commit_reversible_command ();