[Tizen] Add screen and client rotation itself function
[platform/core/uifw/dali-core.git] / dali / internal / event / common / scene-impl.cpp
old mode 100644 (file)
new mode 100755 (executable)
index 2a3ad37..208c1f7
@@ -48,7 +48,17 @@ ScenePtr Scene::New( Size size )
   ScenePtr scene = new Scene;
 
   // Second-phase construction
-  scene->Initialize( size );
+  scene->Initialize( size, 0 );
+
+  return scene;
+}
+
+ScenePtr Scene::New( Size size, int orientation )
+{
+  ScenePtr scene = new Scene;
+
+  // Second-phase construction
+  scene->Initialize( size, orientation );
 
   return scene;
 }
@@ -95,7 +105,7 @@ Scene::~Scene()
   // When this destructor is called, the scene has either already been removed from Core or Core has already been destroyed
 }
 
-void Scene::Initialize( Size size )
+void Scene::Initialize( Size size, int orientation )
 {
   ThreadLocalStorage* tls = ThreadLocalStorage::GetInternal();
 
@@ -131,6 +141,7 @@ void Scene::Initialize( Size size )
   // Create the default render-task and ensure clear is enabled on it to show the background color
   RenderTaskPtr renderTask = mRenderTaskList->CreateTask( mRootLayer.Get(), mDefaultCamera.Get() );
   renderTask->SetClearEnabled(true);
+  mSurfaceOrientation = orientation;
 
   SurfaceResized( size.width, size.height, mSurfaceOrientation, false );
 
@@ -380,6 +391,11 @@ Integration::Scene::WheelEventSignalType& Scene::WheelEventSignal()
   return mWheelEventSignal;
 }
 
+std::vector<Dali::Internal::SceneGraph::DirtyRect>& Scene::GetItemsDirtyRects()
+{
+  return mItemsDirtyRects;
+}
+
 } // Internal
 
 } // Dali