summaryrefslogtreecommitdiffstats
path: root/media/libmediaplayerservice/nuplayer/NuPlayerDriver.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'media/libmediaplayerservice/nuplayer/NuPlayerDriver.cpp')
-rw-r--r--media/libmediaplayerservice/nuplayer/NuPlayerDriver.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/media/libmediaplayerservice/nuplayer/NuPlayerDriver.cpp b/media/libmediaplayerservice/nuplayer/NuPlayerDriver.cpp
index 35cd514..7dd54c1 100644
--- a/media/libmediaplayerservice/nuplayer/NuPlayerDriver.cpp
+++ b/media/libmediaplayerservice/nuplayer/NuPlayerDriver.cpp
@@ -626,12 +626,15 @@ void NuPlayerDriver::notifyListener_l(
switch (msg) {
case MEDIA_PLAYBACK_COMPLETE:
{
- if (mLooping && mState != STATE_RESET_IN_PROGRESS) {
- mPlayer->seekToAsync(0);
- break;
+ if (mState != STATE_RESET_IN_PROGRESS) {
+ if (mLooping) {
+ mPlayer->seekToAsync(0);
+ break;
+ }
+
+ mPlayer->pause();
+ mState = STATE_PAUSED;
}
- mPlayer->pause();
- mState = STATE_PAUSED;
// fall through
}