--- a/vtuis/lcvtplugin/src/control/clcvtlocalvideoplayer.cpp Wed Aug 18 09:50:25 2010 +0300
+++ b/vtuis/lcvtplugin/src/control/clcvtlocalvideoplayer.cpp Thu Sep 02 20:28:30 2010 +0300
@@ -51,7 +51,6 @@
CLcVtVideoPlayerBase( avtSession, aLcAudioControl ),
iCameraHandler( aCameraHandler )
{
- iIsPlaying = ETrue;
iOrientationChanged = EFalse;
}
@@ -77,8 +76,17 @@
//
MLcVideoPlayer::TLcVideoPlayerState
CLcVtLocalVideoPlayer::LcVideoPlayerState() const
- {
- TLcVideoPlayerState playerState = MLcVideoPlayer::EPlaying;
+ {
+ TLcVideoPlayerState playerState;
+ if ( ivtSession->LcVtStates().MediaState().IsVideo() )
+ {
+ playerState = MLcVideoPlayer::EPlaying;
+ }
+ else
+ {
+ playerState = MLcVideoPlayer::EPaused;
+ }
+ __VTPRINT2( DEBUG_GEN, "CLcVtLocalVideoPlayer.LcVideoPlayerState = %d", playerState )
return playerState;
}
@@ -88,7 +96,7 @@
//
TBool CLcVtLocalVideoPlayer::LcIsPlayingL()
{
- TBool result = ivtSession->LcVtStates().MediaState().IsVideo();
+ TBool result = (LcVideoPlayerState() == MLcVideoPlayer::EPlaying);
__VTPRINT2( DEBUG_GEN, "CLcVtLocalVideoPlayer.LcIsPlayingL = %d", result )
return result;
}
@@ -100,7 +108,6 @@
void CLcVtLocalVideoPlayer::LcPlayL(TLcVideoPlayerSource /*aSource*/)
{
__VTPRINT( DEBUG_GEN, "CLcVtLocalVideoPlayer.LcPlayL" )
- iIsPlaying = ETrue;
ivtSession->HandleCommandL(EPluginCmdEnableVideo);
}
@@ -111,7 +118,6 @@
void CLcVtLocalVideoPlayer::LcPauseL()
{
__VTPRINT( DEBUG_GEN, "CLcVtLocalVideoPlayer.LcPauseL" )
- iIsPlaying = EFalse;
ivtSession->HandleCommandL(EPluginCmdDisableVideo);
}