]> git.sur5r.net Git - minitube/blobdiff - src/mediaview.cpp
Fix build without APP_SNAPSHOT
[minitube] / src / mediaview.cpp
index 07443212f01c028a45827dba2589684e8248c72b..302c77a1ea478d6ca0c91329c42eb3fba6b48f86 100644 (file)
@@ -404,10 +404,12 @@ void MediaView::stop() {
     Phonon::SeekSlider *slider = MainWindow::instance()->getSeekSlider();
 #endif
 
+#ifdef APP_SNAPSHOT
     if (snapshotSettings) {
         delete snapshotSettings;
         snapshotSettings = 0;
     }
+#endif
 }
 
 const QString & MediaView::getCurrentVideoId() {
@@ -478,11 +480,13 @@ void MediaView::activeRowChanged(int row) {
     slider->setValue(0);
 #endif
 
+#ifdef APP_SNAPSHOT
     if (snapshotSettings) {
         delete snapshotSettings;
         snapshotSettings = 0;
         MainWindow::instance()->adjustStatusBarVisibility();
     }
+#endif
 
     // see you in gotStreamUrl...
 }
@@ -646,7 +650,7 @@ void MediaView::aboutToFinish() {
 #ifdef APP_PHONON
     qint64 currentTime = mediaObject->currentTime();
     qint64 totalTime = mediaObject->totalTime();
-    qDebug() << __PRETTY_FUNCTION__ << currentTime << totalTime;
+    // qDebug() << __PRETTY_FUNCTION__ << currentTime << totalTime;
     if (totalTime < 1 || currentTime + 10000 < totalTime) {
         // QTimer::singleShot(500, this, SLOT(playbackResume()));
         mediaObject->seek(currentTime);
@@ -661,7 +665,7 @@ void MediaView::playbackFinished() {
 #ifdef APP_PHONON
     const qint64 totalTime = mediaObject->totalTime();
     const qint64 currentTime = mediaObject->currentTime();
-    qDebug() << __PRETTY_FUNCTION__ << mediaObject->currentTime() << totalTime;
+    // qDebug() << __PRETTY_FUNCTION__ << mediaObject->currentTime() << totalTime;
     // add 10 secs for imprecise Phonon backends (VLC, Xine)
     if (currentTime > 0 && currentTime + 10000 < totalTime) {
         // mediaObject->seek(currentTime);
@@ -679,7 +683,7 @@ void MediaView::playbackResume() {
     if (stopped) return;
 #ifdef APP_PHONON
     const qint64 currentTime = mediaObject->currentTime();
-    qDebug() << __PRETTY_FUNCTION__ << currentTime;
+    // qDebug() << __PRETTY_FUNCTION__ << currentTime;
     if (currentTime > 0)
         mediaObject->seek(currentTime);
     mediaObject->play();