add player_prepare when SetPlayPosition() 21/199221/2
authorJoogab Yun <joogab.yun@samsung.com>
Thu, 7 Feb 2019 08:10:35 +0000 (17:10 +0900)
committerJoogab Yun <joogab.yun@samsung.com>
Fri, 8 Feb 2019 01:06:05 +0000 (10:06 +0900)
Change-Id: I1bb4ec2403b477ecdc17a267b88f4ab510ee7014

dali-extension/video-player/tizen-video-player.cpp

index ce33ff42a1e8141996629a22b49ace973a9dde0b..ebd3895a23acbb6e4bf59343ec3dc6d1d2cfad3b 100755 (executable)
@@ -455,6 +455,14 @@ void TizenVideoPlayer::SetPlayPosition( int millisecond )
 
   GetPlayerState( &mPlayerState );
 
+  if( mPlayerState == PLAYER_STATE_IDLE )
+  {
+    error = player_prepare( mPlayer );
+    LogPlayerError( error );
+
+    GetPlayerState( &mPlayerState ); // Check the status again.
+  }
+
   if( mPlayerState == PLAYER_STATE_READY ||
       mPlayerState == PLAYER_STATE_PLAYING ||
       mPlayerState == PLAYER_STATE_PAUSED