Add the synchronization between Ui and Video player
[platform/core/uifw/dali-adaptor.git] / dali / devel-api / adaptor-framework / video-player.cpp
index 870571b..ecbd537 100755 (executable)
@@ -46,7 +46,20 @@ VideoPlayer VideoPlayer::New()
 
   if( player )
   {
-    player->Initialize();
+    Dali::Actor actor;
+    player->Initialize( actor, VideoSyncMode::DISABLED );
+  }
+
+  return VideoPlayer( player.Get() );
+}
+
+VideoPlayer VideoPlayer::New( Dali::Actor actor, VideoSyncMode syncMode )
+{
+  Internal::Adaptor::VideoPlayerPtr player = Internal::Adaptor::VideoPlayer::New();
+
+  if( player )
+  {
+    player->Initialize( actor, syncMode );
   }
 
   return VideoPlayer( player.Get() );
@@ -201,5 +214,15 @@ Any VideoPlayer::GetMediaPlayer()
   return GetImplementation( *this ).GetMediaPlayer();
 }
 
+void VideoPlayer::StartSynchronization()
+{
+  GetImplementation( *this ).StartSynchronization();
+}
+
+void VideoPlayer::FinishSynchronization()
+{
+  GetImplementation( *this ).FinishSynchronization();
+}
+
 } // namespace Dali;