[Tizen] Sync for libds
[platform/core/uifw/dali-adaptor.git] / dali / devel-api / adaptor-framework / offscreen-application.cpp
index 5c1ea07..252aa80 100644 (file)
  *
  */
 
-// INTERNAL INCLUDES
-#include <dali/internal/offscreen/common/offscreen-application-impl.h>
-
 // CLASS HEADER
 #include <dali/devel-api/adaptor-framework/offscreen-application.h>
 
+// INTERNAL INCLUDES
+#include <dali/internal/offscreen/common/offscreen-application-impl.h>
+
 namespace Dali
 {
-OffscreenApplication OffscreenApplication::New( uint16_t width, uint16_t height, bool isTranslucent )
+OffscreenApplication OffscreenApplication::New(uint16_t width, uint16_t height, bool isTranslucent, OffscreenApplication::RenderMode renderMode)
 {
-  Dali::Any surface;
-  IntrusivePtr< Internal::OffscreenApplication > impl = Internal::OffscreenApplication::New( width, height, surface, isTranslucent );
+  Dali::Any                                    surface;
+  IntrusivePtr<Internal::OffscreenApplication> impl = Internal::OffscreenApplication::New(width, height, surface, isTranslucent, renderMode);
 
-  OffscreenApplication offscreenApplication = OffscreenApplication( impl.Get() );
+  OffscreenApplication offscreenApplication = OffscreenApplication(impl.Get());
 
   return offscreenApplication;
 }
 
-OffscreenApplication OffscreenApplication::New( Dali::Any surface, bool isTranslucent )
+OffscreenApplication OffscreenApplication::New(Dali::Any surface, bool isTranslucent, OffscreenApplication::RenderMode renderMode)
 {
-  IntrusivePtr< Internal::OffscreenApplication > impl = Internal::OffscreenApplication::New( 0, 0, surface, isTranslucent );
+  IntrusivePtr<Internal::OffscreenApplication> impl = Internal::OffscreenApplication::New(0, 0, surface, isTranslucent, renderMode);
 
-  OffscreenApplication offscreenApplication = OffscreenApplication( impl.Get() );
+  OffscreenApplication offscreenApplication = OffscreenApplication(impl.Get());
 
   return offscreenApplication;
 }
 
-OffscreenApplication::OffscreenApplication()
-{
-}
+OffscreenApplication::OffscreenApplication() = default;
 
-OffscreenApplication::OffscreenApplication( const OffscreenApplication& offscreenApplication )
-: BaseHandle( offscreenApplication )
-{
-}
+OffscreenApplication::OffscreenApplication(const OffscreenApplication& offscreenApplication) = default;
 
-OffscreenApplication& OffscreenApplication::operator=( const OffscreenApplication& offscreenApplication )
-{
-  if( *this != offscreenApplication )
-  {
-    BaseHandle::operator=( offscreenApplication );
-  }
-  return *this;
-}
+OffscreenApplication& OffscreenApplication::operator=(const OffscreenApplication& offscreenApplication) = default;
 
-OffscreenApplication::~OffscreenApplication()
-{
-}
+OffscreenApplication::~OffscreenApplication() = default;
 
-void OffscreenApplication::Run()
+void OffscreenApplication::Start()
 {
-  Internal::GetImplementation( *this ).Run();
+  Internal::GetImplementation(*this).Start();
 }
 
 void OffscreenApplication::Stop()
 {
-  Internal::GetImplementation( *this ).Stop();
+  Internal::GetImplementation(*this).Stop();
 }
 
 Dali::OffscreenWindow OffscreenApplication::GetWindow()
 {
-  return Internal::GetImplementation( *this ).GetWindow();
+  return Internal::GetImplementation(*this).GetWindow();
+}
+
+void OffscreenApplication::RenderOnce()
+{
+  Internal::GetImplementation(*this).RenderOnce();
 }
 
 OffscreenApplication::OffscreenApplicationSignalType& OffscreenApplication::InitSignal()
 {
-  return Internal::GetImplementation( *this ).InitSignal();
+  return Internal::GetImplementation(*this).InitSignal();
 }
 
 OffscreenApplication::OffscreenApplicationSignalType& OffscreenApplication::TerminateSignal()
 {
-  return Internal::GetImplementation( *this ).TerminateSignal();
+  return Internal::GetImplementation(*this).TerminateSignal();
 }
 
-OffscreenApplication::OffscreenApplication( Internal::OffscreenApplication* offscreenApplication )
-: BaseHandle( offscreenApplication )
+OffscreenApplication::OffscreenApplication(Internal::OffscreenApplication* offscreenApplication)
+: BaseHandle(offscreenApplication)
 {
 }
 
-}  // namespace Dali
+} // namespace Dali