From e2e536eab73dc7d1e2294078628eea80ecf6d120 Mon Sep 17 00:00:00 2001 From: Florian Jung Date: Sun, 5 Jun 2011 22:05:16 +0000 Subject: speeded up the arranger's part canvas --- muse2/muse/app.cpp | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'muse2/muse/app.cpp') diff --git a/muse2/muse/app.cpp b/muse2/muse/app.cpp index 72cdad6a..04c55b01 100644 --- a/muse2/muse/app.cpp +++ b/muse2/muse/app.cpp @@ -2971,14 +2971,13 @@ void MusE::cmd(int cmd) arranger->cmd(Arranger::CMD_INSERT_EMPTYMEAS); break; case CMD_DELETE: - song->startUndo(); - if (song->msgRemoveParts()) { - song->endUndo(SC_PART_REMOVED); - break; - } - else - audio->msgRemoveTracks(); - song->endUndo(SC_TRACK_REMOVED); + if (!song->msgRemoveParts()) //automatically does undo if neccessary and returns true then + { + //msgRemoveParts() returned false -> no parts to remove? + song->startUndo(); + audio->msgRemoveTracks(); //TODO FINDME this could still be speeded up! + song->endUndo(SC_TRACK_REMOVED); + } break; case CMD_DELETE_TRACK: song->startUndo(); -- cgit v1.2.3