Change window rotaton policy
authorWonsik Jung <sidein@samsung.com>
Thu, 19 Dec 2019 02:08:22 +0000 (11:08 +0900)
committerWonsik Jung <sidein@samsung.com>
Thu, 19 Dec 2019 02:08:30 +0000 (11:08 +0900)
This reverts commit 237bc77bb5f822b949df01f03202781174e444fe.

15 files changed:
dali/internal/window-system/android/window-base-android.cpp
dali/internal/window-system/android/window-base-android.h
dali/internal/window-system/common/window-base.h
dali/internal/window-system/common/window-impl.cpp
dali/internal/window-system/common/window-impl.h
dali/internal/window-system/common/window-render-surface.cpp
dali/internal/window-system/tizen-wayland/ecore-wl/window-base-ecore-wl.cpp
dali/internal/window-system/tizen-wayland/ecore-wl/window-base-ecore-wl.h
dali/internal/window-system/tizen-wayland/ecore-wl2/window-base-ecore-wl2.cpp
dali/internal/window-system/tizen-wayland/ecore-wl2/window-base-ecore-wl2.h
dali/internal/window-system/ubuntu-x11/window-base-ecore-x.cpp
dali/internal/window-system/ubuntu-x11/window-base-ecore-x.h
dali/internal/window-system/windows/window-base-win.cpp
dali/internal/window-system/windows/window-base-win.h
dali/public-api/adaptor-framework/window.cpp

index 86680f6..b894fa0 100644 (file)
@@ -190,11 +190,11 @@ void WindowBaseAndroid::Activate()
 {
 }
 
-void WindowBaseAndroid::SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations )
+void WindowBaseAndroid::SetAvailableAnlges( const std::vector< int >& angles )
 {
 }
 
-void WindowBaseAndroid::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
+void WindowBaseAndroid::SetPreferredAngle( int angle )
 {
 }
 
index 239605d..86e8ddc 100644 (file)
@@ -198,14 +198,14 @@ public:
   virtual void Activate() override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableOrientations()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableAnlges()
    */
-  virtual void SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations ) override;
+  virtual void SetAvailableAnlges( const std::vector< int >& angles  ) override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredOrientation()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredAngle()
    */
-  virtual void SetPreferredOrientation( Dali::Window::WindowOrientation orientation ) override;
+  virtual void SetPreferredAngle( int angle ) override;
 
   /**
    * @copydoc Dali::Internal::Adaptor::WindowBase::SetAcceptFocus()
index 4d3454c..9871611 100644 (file)
@@ -181,12 +181,12 @@ public:
   /**
    * @copydoc Dali::Window::SetAvailableOrientations()
    */
-  virtual void SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations ) = 0;
+  virtual void SetAvailableAnlges( const std::vector< int >& angles ) = 0;
 
   /**
    * @copydoc Dali::Window::SetPreferredOrientation()
    */
-  virtual void SetPreferredOrientation( Dali::Window::WindowOrientation orientation ) = 0;
+  virtual void SetPreferredAngle( int angle ) = 0;
 
   /**
    * @copydoc Dali::Window::SetAcceptFocus()
index 271d337..1e9e79b 100644 (file)
@@ -36,6 +36,7 @@
 #include <dali/internal/window-system/common/render-surface-factory.h>
 #include <dali/internal/window-system/common/window-factory.h>
 #include <dali/internal/window-system/common/window-base.h>
+#include <dali/internal/window-system/common/window-system.h>
 #include <dali/internal/window-system/common/window-render-surface.h>
 #include <dali/internal/window-system/common/window-visibility-observer.h>
 
@@ -73,10 +74,11 @@ Window::Window()
   mResizeEnabled( false ),
   mType( Dali::Window::NORMAL ),
   mParentWindow( NULL ),
-  mPreferredOrientation( Dali::Window::PORTRAIT ),
+  mPreferredAngle( 0 ),
   mRotationAngle( 0 ),
   mWindowWidth( 0 ),
   mWindowHeight( 0 ),
+  mOrientationMode( Internal::Adaptor::Window::OrientationMode::PORTRAIT ),
   mFocusChangedSignal(),
   mResizedSignal(),
   mDeleteRequestSignal(),
@@ -125,6 +127,18 @@ void Window::Initialize(const PositionSize& positionSize, const std::string& nam
   mWindowSurface->Map();
 
   mOrientation = Orientation::New( this );
+
+  // Get OrientationMode
+  int screenWidth, screenHeight;
+  WindowSystem::GetScreenSize( screenWidth, screenHeight );
+  if( screenWidth > screenHeight )
+  {
+    mOrientationMode = Internal::Adaptor::Window::OrientationMode::LANDSCAPE;
+  }
+  else
+  {
+    mOrientationMode = Internal::Adaptor::Window::OrientationMode::PORTRAIT;
+  }
 }
 
 void Window::OnAdaptorSet(Dali::Adaptor& adaptor)
@@ -198,12 +212,12 @@ Dali::RenderTaskList Window::GetRenderTaskList() const
 void Window::AddAvailableOrientation( Dali::Window::WindowOrientation orientation )
 {
   bool found = false;
-
   if( orientation <= Dali::Window::LANDSCAPE_INVERSE )
   {
-    for( std::size_t i = 0; i < mAvailableOrientations.size(); i++ )
+    int convertedAngle = ConvertToAngle( orientation );
+    for( std::size_t i = 0; i < mAvailableAngles.size(); i++ )
     {
-      if( mAvailableOrientations[i] == orientation )
+      if( mAvailableAngles[i] == convertedAngle )
       {
         found = true;
         break;
@@ -212,54 +226,113 @@ void Window::AddAvailableOrientation( Dali::Window::WindowOrientation orientatio
 
     if( !found )
     {
-      mAvailableOrientations.push_back( orientation );
-      SetAvailableOrientations( mAvailableOrientations );
+      mAvailableAngles.push_back( convertedAngle );
+      SetAvailableAnlges( mAvailableAngles );
     }
   }
 }
 
 void Window::RemoveAvailableOrientation( Dali::Window::WindowOrientation orientation )
 {
-  for( std::vector<Dali::Window::WindowOrientation>::iterator iter = mAvailableOrientations.begin();
-       iter != mAvailableOrientations.end(); ++iter )
+  int convertedAngle = ConvertToAngle( orientation );
+  for( std::vector< int >::iterator iter = mAvailableAngles.begin();
+       iter != mAvailableAngles.end(); ++iter )
   {
-    if( *iter == orientation )
+    if( *iter == convertedAngle )
     {
-      mAvailableOrientations.erase( iter );
+      mAvailableAngles.erase( iter );
       break;
     }
   }
-  SetAvailableOrientations( mAvailableOrientations );
+
+  SetAvailableAnlges( mAvailableAngles );
 }
 
-void Window::SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations )
+void Window::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
 {
-  if( orientations.size() > 4 )
-  {
-    DALI_LOG_INFO( gWindowLogFilter, Debug::Verbose, "Window::SetAvailableOrientations: Invalid vector size! [%d]\n", orientations.size() );
-    return;
-  }
-
-  mAvailableOrientations = orientations;
-
-  mWindowBase->SetAvailableOrientations( mAvailableOrientations );
+  mPreferredAngle = ConvertToAngle( orientation );
+  mWindowBase->SetPreferredAngle( mPreferredAngle );
 }
 
-const std::vector< Dali::Window::WindowOrientation >& Window::GetAvailableOrientations()
+Dali::Window::WindowOrientation Window::GetPreferredOrientation()
 {
-  return mAvailableOrientations;
+  Dali::Window::WindowOrientation preferredOrientation = ConvertToOrientation( mPreferredAngle );
+  return preferredOrientation;
 }
 
-void Window::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
+void Window::SetAvailableAnlges( const std::vector< int >& angles )
 {
-  mPreferredOrientation = orientation;
+  if( angles.size() > 4 )
+  {
+    DALI_LOG_INFO( gWindowLogFilter, Debug::Verbose, "Window::SetAvailableAnlges: Invalid vector size! [%d]\n", angles.size() );
+    return;
+  }
 
-  mWindowBase->SetPreferredOrientation( mPreferredOrientation );
+  mWindowBase->SetAvailableAnlges( angles );
 }
 
-Dali::Window::WindowOrientation Window::GetPreferredOrientation()
+int Window::ConvertToAngle( Dali::Window::WindowOrientation orientation )
 {
-  return mPreferredOrientation;
+  int convertAngle = static_cast< int >( orientation );
+  if( mOrientationMode == Internal::Adaptor::Window::OrientationMode::LANDSCAPE )
+  {
+    switch( orientation )
+    {
+      case Dali::Window::LANDSCAPE:
+      {
+        convertAngle = 0;
+        break;
+      }
+      case Dali::Window::PORTRAIT:
+      {
+        convertAngle = 90;
+        break;
+      }
+      case Dali::Window::LANDSCAPE_INVERSE:
+      {
+        convertAngle = 180;
+        break;
+      }
+      case Dali::Window::PORTRAIT_INVERSE:
+      {
+        convertAngle = 270;
+        break;
+      }
+    }
+  }
+  return convertAngle;
+}
+
+Dali::Window::WindowOrientation Window::ConvertToOrientation( int angle )
+{
+  Dali::Window::WindowOrientation orientation = static_cast< Dali::Window::WindowOrientation >( angle );
+  if( mOrientationMode == Internal::Adaptor::Window::OrientationMode::LANDSCAPE )
+  {
+    switch( angle )
+    {
+      case 0:
+      {
+        orientation = Dali::Window::LANDSCAPE;
+        break;
+      }
+      case 90:
+      {
+        orientation = Dali::Window::PORTRAIT;
+        break;
+      }
+      case 180:
+      {
+        orientation = Dali::Window::LANDSCAPE_INVERSE;
+        break;
+      }
+      case 270:
+      {
+        orientation = Dali::Window::PORTRAIT_INVERSE;
+        break;
+      }
+    }
+  }
+  return orientation;
 }
 
 Dali::Any Window::GetNativeHandle() const
index be1a640..229d091 100644 (file)
@@ -143,16 +143,6 @@ public:
   void RemoveAvailableOrientation(Dali::Window::WindowOrientation orientation);
 
   /**
-   * @copydoc Dali::Window::SetAvailableOrientations()
-   */
-  void SetAvailableOrientations(const std::vector<Dali::Window::WindowOrientation>& orientations);
-
-  /**
-   * @copydoc Dali::Window::GetAvailableOrientations()
-   */
-  const std::vector<Dali::Window::WindowOrientation>& GetAvailableOrientations();
-
-  /**
    * @copydoc Dali::Window::SetPreferredOrientation()
    */
   void SetPreferredOrientation(Dali::Window::WindowOrientation orientation);
@@ -362,6 +352,18 @@ public: // Dali::Internal::Adaptor::SceneHolder
 private:
 
   /**
+   * @brief Enumeration for orietation mode.
+   * The Orientation Mode is related to screen size.
+   * If screen width is longer than height, the Orientation Mode will have LANDSCAPE.
+   * Otherwise screen width is shorter than height or same, the Orientation Mode will have PORTRAIT.
+   */
+  enum class OrientationMode
+  {
+    PORTRAIT = 0,
+    LANDSCAPE
+  };
+
+  /**
    * Private constructor.
    * @sa Window::New()
    */
@@ -402,6 +404,21 @@ private:
    */
   void OnTransitionEffectEvent( DevelWindow::EffectState state, DevelWindow::EffectType type );
 
+  /**
+   * @brief Set available orientation to window base.
+   */
+  void SetAvailableAnlges( const std::vector< int >& angles );
+
+  /**
+   * @brief Convert from window orientation to angle using OrientationMode.
+   */
+  int ConvertToAngle( Dali::Window::WindowOrientation orientation );
+
+  /**
+   * @brief Convert from angle to window orientation using OrientationMode.
+   */
+  Dali::Window::WindowOrientation ConvertToOrientation( int angle );
+
 private: // Dali::Internal::Adaptor::SceneHolder
 
   /**
@@ -511,9 +528,9 @@ private:
   Dali::Window::Type                    mType;
   Dali::Window                          mParentWindow;
 
-  OrientationPtr                               mOrientation;
-  std::vector<Dali::Window::WindowOrientation> mAvailableOrientations;
-  Dali::Window::WindowOrientation              mPreferredOrientation;
+  OrientationPtr                        mOrientation;
+  std::vector< int >                    mAvailableAngles;
+  int                                   mPreferredAngle;
 
   int                                   mRotationAngle;     ///< The angle of the rotation
   int                                   mWindowWidth;       ///< The width of the window
@@ -521,6 +538,8 @@ private:
 
   EventHandlerPtr                       mEventHandler;      ///< The window events handler
 
+  OrientationMode                       mOrientationMode;
+
   // Signals
   IndicatorSignalType                   mIndicatorVisibilityChangedSignal;
   FocusSignalType                       mFocusChangedSignal;
index 6c28f12..4905068 100644 (file)
@@ -100,7 +100,6 @@ void WindowRenderSurface::Initialize( Any surface )
     // Default window size == screen size
     mPositionSize.x = 0;
     mPositionSize.y = 0;
-
     WindowSystem::GetScreenSize( mPositionSize.width, mPositionSize.height );
   }
 
index 84b9b2e..835c24c 100644 (file)
@@ -268,6 +268,7 @@ static Eina_Bool EcoreEventRotate( void* data, int type, void* event )
   WindowBaseEcoreWl* windowBase = static_cast< WindowBaseEcoreWl* >( data );
   if( windowBase )
   {
+    DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl::EcoreEventRotate\n" );
     windowBase->OnRotation( data, type, event );
   }
   return ECORE_CALLBACK_PASS_ON;
@@ -809,7 +810,7 @@ void WindowBaseEcoreWl::OnRotation( void* data, int type, void* event )
 
   if( ev->win == static_cast< unsigned int >( ecore_wl_window_id_get( mEcoreWindow ) ) )
   {
-    DALI_LOG_INFO( gWindowBaseLogFilter, Debug::Concise, "WindowBaseEcoreWl::OnRotation\n" );
+    DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl::OnRotation, angle: %d, width: %d, height: %d\n", ev->angle, ev->w, ev->h );
 
     RotationEvent rotationEvent;
     rotationEvent.angle = ev->angle;
@@ -1360,19 +1361,22 @@ void WindowBaseEcoreWl::Activate()
   ecore_wl_window_activate( mEcoreWindow );
 }
 
-void WindowBaseEcoreWl::SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations )
+void WindowBaseEcoreWl::SetAvailableAnlges( const std::vector< int >& angles )
 {
   int rotations[4] = { 0 };
-  for( std::size_t i = 0; i < orientations.size(); ++i )
+  DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl::SetAvailableAnlges, angle's count: %d\n", angles.size() );
+  for( std::size_t i = 0; i < angles.size(); ++i )
   {
-    rotations[i] = static_cast< int >( orientations[i] );
+    rotations[i] = static_cast< int >( angles[i] );
+    DALI_LOG_RELEASE_INFO( "%d ", rotations[i] );
   }
-  ecore_wl_window_rotation_available_rotations_set( mEcoreWindow, rotations, orientations.size() );
+  ecore_wl_window_rotation_available_rotations_set( mEcoreWindow, rotations, angles.size() );
 }
 
-void WindowBaseEcoreWl::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
+void WindowBaseEcoreWl::SetPreferredAngle( int angle )
 {
-  ecore_wl_window_rotation_preferred_rotation_set( mEcoreWindow, orientation );
+  DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl::SetPreferredAngle, angle: %d\n", angle );
+  ecore_wl_window_rotation_preferred_rotation_set( mEcoreWindow, angle );
 }
 
 void WindowBaseEcoreWl::SetAcceptFocus( bool accept )
index e54ab94..5811b5c 100644 (file)
@@ -265,14 +265,14 @@ public:
   virtual void Activate() override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableOrientations()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableAnlges()
    */
-  virtual void SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations ) override;
+  virtual void SetAvailableAnlges( const std::vector< int >& angles ) override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredOrientation()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredAngle()
    */
-  virtual void SetPreferredOrientation( Dali::Window::WindowOrientation orientation ) override;
+  virtual void SetPreferredAngle( int angle ) override;
 
   /**
    * @copydoc Dali::Internal::Adaptor::WindowBase::SetAcceptFocus()
index 6544ba6..40e27c3 100755 (executable)
@@ -270,6 +270,7 @@ static Eina_Bool EcoreEventRotate( void* data, int type, void* event )
   WindowBaseEcoreWl2* windowBase = static_cast< WindowBaseEcoreWl2* >( data );
   if( windowBase )
   {
+    DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl2::EcoreEventRotate\n" );
     windowBase->OnRotation( data, type, event );
   }
   return ECORE_CALLBACK_PASS_ON;
@@ -874,7 +875,7 @@ void WindowBaseEcoreWl2::OnRotation( void* data, int type, void* event )
 
   if( ev->win == static_cast< unsigned int >( ecore_wl2_window_id_get( mEcoreWindow ) ) )
   {
-    DALI_LOG_INFO( gWindowBaseLogFilter, Debug::Concise, "WindowBaseEcoreWl::OnRotation\n" );
+    DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl2::OnRotation, angle: %d, width: %d, height: %d\n", ev->angle, ev->w, ev->h );
 
     RotationEvent rotationEvent;
     rotationEvent.angle = ev->angle;
@@ -1453,19 +1454,22 @@ void WindowBaseEcoreWl2::Activate()
   ecore_wl2_window_activate( mEcoreWindow );
 }
 
-void WindowBaseEcoreWl2::SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations )
+void WindowBaseEcoreWl2::SetAvailableAnlges( const std::vector< int >& angles )
 {
   int rotations[4] = { 0 };
-  for( std::size_t i = 0; i < orientations.size(); ++i )
+  DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl2::SetAvailableAnlges, angle's count: %d\n", angles.size() );
+  for( std::size_t i = 0; i < angles.size(); ++i )
   {
-    rotations[i] = static_cast< int >( orientations[i] );
+    rotations[i] = static_cast< int >( angles[i] );
+    DALI_LOG_RELEASE_INFO( "%d ", rotations[i] );
   }
-  ecore_wl2_window_available_rotations_set( mEcoreWindow, rotations, orientations.size() );
+  ecore_wl2_window_available_rotations_set( mEcoreWindow, rotations, angles.size() );
 }
 
-void WindowBaseEcoreWl2::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
+void WindowBaseEcoreWl2::SetPreferredAngle( int angle )
 {
-  ecore_wl2_window_preferred_rotation_set( mEcoreWindow, orientation );
+  DALI_LOG_RELEASE_INFO( "WindowBaseEcoreWl2::SetPreferredAngle, angle: %d\n", angle );
+  ecore_wl2_window_preferred_rotation_set( mEcoreWindow, angle );
 }
 
 void WindowBaseEcoreWl2::SetAcceptFocus( bool accept )
index 14985d2..aa0debb 100644 (file)
@@ -275,14 +275,14 @@ public:
   virtual void Activate() override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableOrientations()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableAnlges()
    */
-  virtual void SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations ) override;
+  virtual void SetAvailableAnlges( const std::vector< int >& angles ) override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredOrientation()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredAngle()
    */
-  virtual void SetPreferredOrientation( Dali::Window::WindowOrientation orientation ) override;
+  virtual void SetPreferredAngle( int angle ) override;
 
   /**
    * @copydoc Dali::Internal::Adaptor::WindowBase::SetAcceptFocus()
index 45a4d59..07d6ea4 100755 (executable)
@@ -701,11 +701,11 @@ void WindowBaseEcoreX::Activate()
   ecore_x_netwm_client_active_request( ecore_x_window_root_get( mEcoreWindow ), mEcoreWindow, 1 /* request type, 1:application, 2:pager */, 0 );
 }
 
-void WindowBaseEcoreX::SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations )
+void WindowBaseEcoreX::SetAvailableAnlges( const std::vector< int >& angles )
 {
 }
 
-void WindowBaseEcoreX::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
+void WindowBaseEcoreX::SetPreferredAngle( int angle )
 {
 }
 
index 031445e..8ab7080 100644 (file)
@@ -199,14 +199,14 @@ public:
   virtual void Activate() override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableOrientations()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableAnlges()
    */
-  virtual void SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations ) override;
+  virtual void SetAvailableAnlges( const std::vector< int >& angles ) override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredOrientation()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredAngle()
    */
-  virtual void SetPreferredOrientation( Dali::Window::WindowOrientation orientation ) override;
+  virtual void SetPreferredAngle( int angle ) override;
 
   /**
    * @copydoc Dali::Internal::Adaptor::WindowBase::SetAcceptFocus()
index e1526ff..2ad916c 100755 (executable)
@@ -314,11 +314,11 @@ void WindowBaseWin::Activate()
 {
 }
 
-void WindowBaseWin::SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations )
+void WindowBaseWin::SetAvailableAnlges( const std::vector< int >& angles )
 {
 }
 
-void WindowBaseWin::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
+void WindowBaseWin::SetPreferredAngle( int angle )
 {
 }
 
index f1af92f..460d28f 100755 (executable)
@@ -187,14 +187,14 @@ public:
   virtual void Activate() override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableOrientations()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetAvailableAnlges()
    */
-  virtual void SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations ) override;
+  virtual void SetAvailableAnlges( const std::vector< int >& angles ) override;
 
   /**
-   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredOrientation()
+   * @copydoc Dali::Internal::Adaptor::WindowBase::SetPreferredAngle()
    */
-  virtual void SetPreferredOrientation( Dali::Window::WindowOrientation orientation ) override;
+  virtual void SetPreferredAngle( int angle ) override;
 
   /**
    * @copydoc Dali::Internal::Adaptor::WindowBase::SetAcceptFocus()
index 14e8c04..2edfae3 100644 (file)
@@ -165,7 +165,7 @@ void Window::RemoveAvailableOrientation( WindowOrientation orientation )
   GetImplementation(*this).RemoveAvailableOrientation( orientation );
 }
 
-void Window::SetPreferredOrientation( Dali::Window::WindowOrientation orientation )
+void Window::SetPreferredOrientation( WindowOrientation orientation )
 {
   GetImplementation(*this).SetPreferredOrientation( orientation );
 }