]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Fix the information panel video player in Dolphin.
authorAndrey Bondrov <pulfer@list.ru>
Fri, 24 Oct 2014 06:21:37 +0000 (08:21 +0200)
committerEmmanuel Pescosta <emmanuelpescosta099@gmail.com>
Fri, 24 Oct 2014 06:26:40 +0000 (08:26 +0200)
Patch from ROSA Linux.

BUG: 337107
BUG: 337033
BUG: 334924
CCBUG: 339882
REVIEW: 120745
FIXED-IN: 4.14.3

src/panels/information/phononwidget.cpp

index a36ada180126c6d84452aa43720d59c94b9ef82a..3d9909239c112d03ad9ade7d7ff1e80ebe2dd9ca 100644 (file)
@@ -184,6 +184,13 @@ void PhononWidget::play()
         m_seekSlider->setMediaObject(m_media);
     }
 
+    if (!m_videoPlayer) {
+        m_videoPlayer = new EmbeddedVideoPlayer(this);
+        m_topLayout->insertWidget(0, m_videoPlayer);
+        Phonon::createPath(m_media, m_videoPlayer);
+        applyVideoSize();
+    }
+
     if (!m_audioOutput) {
         m_audioOutput = new Phonon::AudioOutput(Phonon::MusicCategory, this);
         Phonon::createPath(m_media, m_audioOutput);
@@ -217,15 +224,6 @@ void PhononWidget::slotHasVideoChanged(bool hasVideo)
     emit hasVideoChanged(hasVideo);
 
     if (hasVideo) {
-        if (!m_videoPlayer) {
-            // Replay the media to apply path changes
-            m_media->stop();
-            m_videoPlayer = new EmbeddedVideoPlayer(this);
-            m_topLayout->insertWidget(0, m_videoPlayer);
-            Phonon::createPath(m_media, m_videoPlayer);
-            m_media->play();
-        }
-        applyVideoSize();
         m_videoPlayer->show();
     }
 }