Blackberry: Fix playlists not advancing to the next track.
authorThomas McGuire <thomas.mcguire.qnx@kdab.com>
Fri, 27 Jul 2012 09:02:29 +0000 (11:02 +0200)
committerQt by Nokia <qt-info@nokia.com>
Mon, 30 Jul 2012 13:27:15 +0000 (15:27 +0200)
The playlist watches for state changes to the EndOfMedia state, which
wasn't used in the plugin yet.

Change-Id: Ib2a014177df2273cd46baaef1392a73e54daf06c
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Lev Zelenskiy <lev.zelenskiy@nokia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
src/plugins/blackberry/bbmediaplayercontrol.cpp

index 1fe21de..e37c880 100644 (file)
@@ -543,10 +543,12 @@ bool BbMediaPlayerControl::nativeEventFilter(const QByteArray &eventType, void *
                 // playback is stopped because of this.
                 // Ignore other stop event sources, souch as calling mmr_stop() ourselves and
                 // mmr_input_attach().
-                if (m_stopEventsToIgnore > 0)
+                if (m_stopEventsToIgnore > 0) {
                     --m_stopEventsToIgnore;
-                else
+                } else {
+                    setMediaStatus(QMediaPlayer::EndOfMedia);
                     stopInternal(IgnoreMmRenderer);
+                }
                 return false;
             }
         }