summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorAndreas Huber <andih@google.com>2010-04-07 10:24:35 -0700
committerAndreas Huber <andih@google.com>2010-04-07 10:35:18 -0700
commitdac4ee72bac87388a1495e098f39d73168c8078f (patch)
tree59902b5757b00e061e66235144e7a5e4773ee427 /media
parent80eb61776f136c316f45ce4187a8bafedf9b3e88 (diff)
downloadframeworks_av-dac4ee72bac87388a1495e098f39d73168c8078f.zip
frameworks_av-dac4ee72bac87388a1495e098f39d73168c8078f.tar.gz
frameworks_av-dac4ee72bac87388a1495e098f39d73168c8078f.tar.bz2
Report the requested seek time while seek is in progress.
Change-Id: I862bfb801701f9ce54dede51c492e4eb37591894 related-to-bug: 2576102
Diffstat (limited to 'media')
-rw-r--r--media/libstagefright/AwesomePlayer.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/media/libstagefright/AwesomePlayer.cpp b/media/libstagefright/AwesomePlayer.cpp
index 27add0a..e7022f4 100644
--- a/media/libstagefright/AwesomePlayer.cpp
+++ b/media/libstagefright/AwesomePlayer.cpp
@@ -668,7 +668,9 @@ status_t AwesomePlayer::getDuration(int64_t *durationUs) {
}
status_t AwesomePlayer::getPosition(int64_t *positionUs) {
- if (mVideoSource != NULL) {
+ if (mSeeking) {
+ *positionUs = mSeekTimeUs;
+ } else if (mVideoSource != NULL) {
Mutex::Autolock autoLock(mMiscStateLock);
*positionUs = mVideoTimeUs;
} else if (mAudioPlayer != NULL) {
@@ -710,7 +712,6 @@ void AwesomePlayer::seekAudioIfNecessary_l() {
mWatchForAudioSeekComplete = true;
mWatchForAudioEOS = true;
- mSeeking = false;
mSeekNotificationSent = false;
}
}
@@ -1001,6 +1002,8 @@ void AwesomePlayer::onCheckAudioStatus() {
notifyListener_l(MEDIA_SEEK_COMPLETE);
mSeekNotificationSent = true;
}
+
+ mSeeking = false;
}
status_t finalStatus;