Move marker undo code to seperate file

This commit is contained in:
Thomas Wilshaw
2021-10-22 22:15:55 +01:00
parent 2840f957bd
commit 7af6f85a7c
7 changed files with 142 additions and 92 deletions
+2 -1
View File
@@ -27,6 +27,7 @@
#include "common/qtutils.h"
#include "core.h"
#include "widget/timebased/timebasedwidget.h"
#include "widget/marker/markerundo.h"
namespace olive {
@@ -95,7 +96,7 @@ void SeekableWidget::DeleteSelected() {
MultiUndoCommand* command = new MultiUndoCommand();
foreach (TimelineMarker *marker, GetActiveTimelineMarkers()) {
command->add_child(new TimeBasedWidget::MarkerRemoveCommand(Core::instance()->GetActiveProject(), marker, timeline_points_->markers()));
command->add_child(new MarkerRemoveCommand(Core::instance()->GetActiveProject(), marker, timeline_points_->markers()));
}
Core::instance()->undo_stack()->pushIfHasChildren(command);