]> git.sesse.net Git - kdenlive/commitdiff
Fix slideshow clips created with invalid frame duration
authorJean-Baptiste Mardelle <jb@kdenlive.org>
Tue, 27 Dec 2011 10:44:52 +0000 (11:44 +0100)
committerJean-Baptiste Mardelle <jb@kdenlive.org>
Tue, 27 Dec 2011 10:44:52 +0000 (11:44 +0100)
src/slideshowclip.cpp

index dbe15e2dc7c1094bbf5742ecacd4424c4a0c92b7..9bbd85422c66ad167a97af1ca016877672be13b9 100644 (file)
@@ -438,14 +438,14 @@ void SlideshowClip::slotMethodChanged(bool active)
 {
     if (active) {
         // User wants mimetype image sequence
-        if (m_view.clip_duration->text().isEmpty()) {
+        if (m_view.clip_duration->text().isEmpty() || m_view.clip_duration->text().length() < 4) {
             m_view.clip_duration->setText(m_timecode.reformatSeparators(KdenliveSettings::image_duration()));
         }
         m_view.stackedWidget->setCurrentIndex(0);
         KdenliveSettings::setSlideshowbymime(true);
     } else {
         // User wants pattern image sequence
-        if (m_view.clip_duration->text().isEmpty()) {
+        if (m_view.clip_duration->text().isEmpty() || m_view.clip_duration->text().length() < 4) {
             m_view.clip_duration->setText(m_timecode.reformatSeparators(KdenliveSettings::sequence_duration()));
         }
         m_view.stackedWidget->setCurrentIndex(1);