]> git.sesse.net Git - kdenlive/commitdiff
Do not show split audio command in undo history if there is nothing to split
authorTill Theato <root@ttill.de>
Wed, 2 Jun 2010 20:43:20 +0000 (20:43 +0000)
committerTill Theato <root@ttill.de>
Wed, 2 Jun 2010 20:43:20 +0000 (20:43 +0000)
svn path=/trunk/kdenlive/; revision=4495

src/customtrackview.cpp
src/customtrackview.h

index 31b9cbc7da967c04f3c8ae1920a2c91a0475c1fb..d3c3b8b8c72b9fdff17d6b9d587085a7bf4be5c6 100644 (file)
@@ -5510,7 +5510,8 @@ void CustomTrackView::splitAudio()
             }
         }
     }
-    m_commandStack->push(splitCommand);
+    if (splitCommand->childCount() > 0)
+        m_commandStack->push(splitCommand);
 }
 
 void CustomTrackView::doSplitAudio(const GenTime &pos, int track, bool split)
index 91543cb8a23f37b8551334914d89763d41986929..504a8874d41d5e2e5afff024f1a4934ed21f2aca 100644 (file)
@@ -130,7 +130,14 @@ public:
     void groupClips(bool group = true);
     void doGroupClips(QList <ItemInfo> clipInfos, QList <ItemInfo> transitionInfos, bool group);
     void loadGroups(const QDomNodeList groups);
+
+    /** @brief Creates SplitAudioCommands for selected clips. */
     void splitAudio();
+
+    /** @brief Seperates the audio of a clip to a audio track.
+    * @param pos Position of the clip to split 
+    * @param track Track of the clip
+    * @param split Split or unsplit */
     void doSplitAudio(const GenTime &pos, int track, bool split);
     void setVideoOnly();
     void setAudioOnly();