From fcbc71cdd6988dd62aeb62b969853e55d74a395d Mon Sep 17 00:00:00 2001 From: Choi Munseok Date: Thu, 23 May 2013 14:07:22 +0900 Subject: [PATCH] Remove Defines Change-Id: I46c8e09107f85657d0a11fe31645d30ec7379dab Signed-off-by: Choi Munseok --- src/ui/FUi_ControlImplManager.cpp | 7 -- src/ui/FUi_ControlManager.cpp | 38 ------- src/ui/FUi_EcoreEvas.cpp | 117 ---------------------- src/ui/FUi_OrientationAgent.cpp | 170 -------------------------------- src/ui/FUi_OrientationAgent.h | 7 -- src/ui/FUi_Window.cpp | 34 ------- src/ui/controls/FUiCtrl_ContextMenu.cpp | 5 - src/ui/controls/FUiCtrl_FormImpl.cpp | 2 - src/ui/controls/FUiCtrl_FrameImpl.cpp | 2 - src/ui/inc/FUiCtrl_FormImpl.h | 2 - src/ui/inc/FUiCtrl_FrameImpl.h | 2 - src/ui/inc/FUi_EcoreEvas.h | 4 - src/ui/inc/FUi_Types.h | 4 - src/ui/inc/FUi_Window.h | 14 --- 14 files changed, 408 deletions(-) diff --git a/src/ui/FUi_ControlImplManager.cpp b/src/ui/FUi_ControlImplManager.cpp index c3de664..f6cbe2f 100644 --- a/src/ui/FUi_ControlImplManager.cpp +++ b/src/ui/FUi_ControlImplManager.cpp @@ -245,15 +245,8 @@ _ControlImplManager::GetCurrentFrame(void) const void _ControlImplManager::OnScreenRotated(int rotation) { -#if defined(WINDOW_BASE_ROTATE) // Do not use the device orientation callback. return; -#else - _ControlManager* pCore = _ControlManager::GetInstance(); - SysAssert(pCore); - - pCore->OnScreenRotated(rotation); -#endif } void diff --git a/src/ui/FUi_ControlManager.cpp b/src/ui/FUi_ControlManager.cpp index 1c899ba..45f8091 100644 --- a/src/ui/FUi_ControlManager.cpp +++ b/src/ui/FUi_ControlManager.cpp @@ -549,32 +549,11 @@ _ControlManager::ActivateWindow(_Window& window) if (window.IsOrientationRoot() == false) { -#if !defined(WINDOW_BASE_ROTATE) - window.ChangeLayout(GetOrientation()); - _EcoreEvas* pEcoreEvas = ::GetEcoreEvasMgr()->GetEcoreEvas(); if (pEcoreEvas) { - pEcoreEvas->RotateWindow(window, ::Convert(__orientationStatus)); - } -#else - // Rotate partial window without Window State Changed Callback. - - _EcoreEvas* pEcoreEvas = ::GetEcoreEvasMgr()->GetEcoreEvas(); - if (pEcoreEvas) - { -#if !defined(WINDOW_OWNEE_PREFERRED) - window.ChangeLayout(GetOrientation()); - pEcoreEvas->RotateWindow(window, ::Convert(__orientationStatus)); -// window.SetRotation(::Convert(__orientationStatus)); -// window.Invalidate(true); - pEcoreEvas->SetWindowPreferredRotation(window, ::Convert(__orientationStatus)); -#else - pEcoreEvas->SetWindowPreferredRotation(window, ::Convert(__orientationStatus)); -#endif } -#endif } r = window.GetControlDelegate().OnAttached(); @@ -909,7 +888,6 @@ _ControlManager::GetScreenRotation(void) const } else { -#if defined(WINDOW_BASE_ROTATE) // int degree = app_get_device_orientation(); unsigned long rotationState = 0; @@ -958,9 +936,6 @@ _ControlManager::GetScreenRotation(void) const } return ::Convert(device_rotation); -#else - return __screenRotation; -#endif } } @@ -1068,19 +1043,6 @@ _ControlManager::RotateScreen(const _Control& control, _ControlRotation screenRo pRootWindow->SetRotation(::Convert(screenRotation)); } -#if !defined(WINDOW_BASE_ROTATE) - // Rotate Ownees. - int owneeCount = control.GetOwneeCount(); - for (int i = 0; i < owneeCount; i++) - { - _Window* pOwnee = control.GetOwnee(i); - if (pOwnee) - { - pEcoreEvas->RotateWindow(*pOwnee, ::Convert(screenRotation)); - } - } -#endif - if (__orientationStatus != screenRotation) { _TouchManager* pTouchManager = _TouchManager::GetInstance(); diff --git a/src/ui/FUi_EcoreEvas.cpp b/src/ui/FUi_EcoreEvas.cpp index b27efae..7952609 100644 --- a/src/ui/FUi_EcoreEvas.cpp +++ b/src/ui/FUi_EcoreEvas.cpp @@ -95,7 +95,6 @@ Ecore_X_Atom __atomAccessibility = 0; int __clipboardHeight = 0; -#if defined(WINDOW_BASE_ROTATE) void OnWindowStateChanged(Ecore_Evas* pEcoreEvas) { @@ -128,7 +127,6 @@ OnWindowStateChanged(Ecore_Evas* pEcoreEvas) } } } -#endif Eina_Bool OnWindowPropertyChanged(void* pData, int type, void* pEvent) @@ -331,50 +329,6 @@ CATCH: Eina_Bool OnWindowShown(void* pData, int type, void* pEvent) { -#if !defined(WINDOW_BASE_ROTATE) - Ecore_X_Event_Window_Show* pEv = (Ecore_X_Event_Window_Show*) pEvent; - if (!pEv) - { - return ECORE_CALLBACK_PASS_ON; - } - - Ecore_X_Window shownWin = pEv->win; - if (shownWin == 0) - { - return ECORE_CALLBACK_PASS_ON; - } - - _ControlManager* pControlManager = _ControlManager::GetInstance(); - if (!pControlManager) - { - return ECORE_CALLBACK_PASS_ON; - } - - int winCount = pControlManager->GetWindowCount(); - - for (int i = 0; i < winCount; i++) - { - _Window* pWindow = pControlManager->GetWindow(i); - if (!pWindow) - { - continue; - } - - Ecore_X_Window win = (Ecore_X_Window)pWindow->GetNativeHandle(); - - if (win == shownWin) - { - bool orientationEnabled = pWindow->IsOrientationEnabled(); - - _EcoreEvas* pEcoreEvas = static_cast<_EcoreEvas*>(pData); - if (pEcoreEvas) - { - pEcoreEvas->SetWindowOrientationEnabled(*pWindow, orientationEnabled); - } - } - } -#endif - return ECORE_CALLBACK_PASS_ON; } @@ -559,10 +513,6 @@ namespace { #define __UNUSED__ -#if !defined(WINDOW_BASE_ROTATE) -Ecore_X_Atom __atomRotateAuto = 0; -#endif - enum _ClipType { _CLIP_TYPE_PRIMARY, @@ -1114,10 +1064,8 @@ _EcoreEvas::_EcoreEvas(void) , __changeBounds(true) , __openClipboard(false) { -#if defined(WINDOW_BASE_ROTATE) int ret = appcore_unset_rotation_cb(); SysLog(NID_UI, "[Window Manager Rotation] appcore_unset_rotation_cb = %d", ret); -#endif __pWindowVisibilityChanged = ecore_event_handler_add(ECORE_X_EVENT_WINDOW_VISIBILITY_CHANGE, OnWindowVisibilityChanged, (void*) this); SysTryReturnVoidResult(NID_UI, __pWindowVisibilityChanged, E_SYSTEM, "[E_SYSTEM] A system error occurred."); @@ -1337,38 +1285,6 @@ _EcoreEvas::RotateWindow(const _Window& window, int orientation, bool rotateEvas } } -#if !defined(WINDOW_BASE_ROTATE) -void -_EcoreEvas::SetWindowOrientationEnabled(const _Window& window, bool enable) -{ - _EflLayer* pLayer = GetEflLayer(window); - if (!pLayer) - { - return; - } - - Ecore_Evas* pEcoreEvas = pLayer->GetEcoreEvas(); - if (!pEcoreEvas) - { - return; - } - - Ecore_X_Window win = (Ecore_X_Window) ecore_evas_window_get(pEcoreEvas); - if (win == 0) - { - return; - } - - if (__atomRotateAuto == 0) - { - __atomRotateAuto = ecore_x_atom_get(ATOM_ROTATE_AUTO); - } - - unsigned int supportRotation = (unsigned int)enable; - ecore_x_window_prop_card32_set(win, __atomRotateAuto, &supportRotation, 1); -} -#endif - _EflLayer* _EcoreEvas::GetEflLayer(const _Window& window) const { @@ -2458,35 +2374,6 @@ _EcoreEvas::SetOwner(const _Window& ownee, const _Control& owner) SysLog(NID_UI, "[Window Order Group][Window : 0x%x] Skip to transient_for_set", owneeWin); } -#if !defined(WINDOW_BASE_ROTATE) - int rotation = GetWindowRotation(*pOwnerWindow); - RotateWindow(ownee, rotation); -#else -#if !defined(WINDOW_OWNEE_PREFERRED) - int* rotations = null; - unsigned int count = 0; - Eina_Bool ret = ecore_evas_wm_rotation_available_rotations_get(pOwnerLayer->GetEcoreEvas(), &rotations, &count); - - if (ret) - { - if (rotations) - { - SetWindowAvailabledRotation(ownee, rotations, count); - free(rotations); - } - } - - bool preferredRoation = pOwnerWindow->GetPreferredRotation(); - if (preferredRoation == true) - { - int preferredRotation = ecore_evas_wm_rotation_preferred_rotation_get(pOwnerLayer->GetEcoreEvas()); - SetWindowPreferredRotation(ownee, preferredRotation); - } - else - { - SetWindowPreferredRotation(ownee, -1); - } -#else // Ownee window // 1. IsLayoutChangable : true // 2. IsRotationSynchronized : true @@ -2523,8 +2410,6 @@ _EcoreEvas::SetOwner(const _Window& ownee, const _Control& owner) int ownerRotation = GetWindowRotation(*pOwnerWindow); SetWindowPreferredRotation(ownee, ownerRotation); } -#endif -#endif SetLastResult(E_SUCCESS); } @@ -2542,7 +2427,6 @@ _EcoreEvas::GetWindowRotation(const _Window& window) return rotation; } -#if defined(WINDOW_BASE_ROTATE) void _EcoreEvas::SetWindowPreferredRotation(const _Window& window, int rotation) { @@ -2643,7 +2527,6 @@ _EcoreEvas::SetWindowRotationBounds(const _Window& window, int rotation, const T SysLog(NID_UI, "[Window Manager Rotation][Window : 0x%x] Set rotation bounds(rot = %d, %d, %d, %d, %d).", win, rotation, winBounds.x, winBounds.y, winBounds.width, winBounds.height); ecore_x_e_window_rotation_geometry_set(win, rotation, winBounds.x, winBounds.y, winBounds.width, winBounds.height); } -#endif // [ToDo] Remove API const _Control* diff --git a/src/ui/FUi_OrientationAgent.cpp b/src/ui/FUi_OrientationAgent.cpp index c441d4e..ce6989f 100644 --- a/src/ui/FUi_OrientationAgent.cpp +++ b/src/ui/FUi_OrientationAgent.cpp @@ -79,9 +79,7 @@ _OrientationAgent::_OrientationAgent(Control& publicControl) , __firePublicEvent(false) , __statusChanged(false) , __updateStatus(true) -#if defined(WINDOW_BASE_ROTATE) , __draw(false) -#endif { _PublicOrientationEvent* pPublicEvent = _PublicOrientationEvent::CreateInstanceN(publicControl); @@ -151,7 +149,6 @@ _OrientationAgent::SetMode(Orientation mode) void _OrientationAgent::Update(bool draw) { -#if defined(WINDOW_BASE_ROTATE) // Update orientation status(Not Auto-mode) // Request rotation to window manager -> async -> Update VEs // Window(not rotation) -> sync -> UpdateVEs @@ -255,117 +252,8 @@ _OrientationAgent::Update(bool draw) // } SysLog(NID_UI, "[Window Manager Rotation] ---------- Update : END ----------"); -#else - _ControlImplManager* pImplManager = _ControlImplManager::GetInstance(); - SysAssert(pImplManager); - - _ControlImpl* pImpl = _ControlImpl::GetInstance(__publicControl); - if (!pImpl) - { - return; - } - - _EcoreEvas* pEcoreEvas = GetEcoreEvasMgr()->GetEcoreEvas(); - if (!pEcoreEvas) - { - return; - } - - _Form* pForm = dynamic_cast<_Form*>(&(pImpl->GetCore())); - if (pForm) - { - _Control* pParent = pForm->GetParent(); - - if (pParent) - { - int index = pParent->GetChildIndex(*pForm); - int childCount = pParent->GetChildCount(); - - if (index == (childCount - 1)) - { - _Window* pWindow = pForm->GetRootWindow(); - if (pWindow) - { - if ((__mode == ORIENTATION_AUTOMATIC) || (__mode == ORIENTATION_AUTOMATIC_FOUR_DIRECTION)) - { - pEcoreEvas->SetWindowOrientationEnabled(*pWindow, true); - pWindow->SetOrientationEnabled(true); - } - else - { - pEcoreEvas->SetWindowOrientationEnabled(*pWindow, false); - pWindow->SetOrientationEnabled(false); - } - } - } - } - } - else - { - _Frame* pFrame = dynamic_cast<_Frame*>(&(pImpl->GetCore())); - if (pFrame) - { - int childCount = pFrame->GetChildCount(); - if (childCount == 0) - { - _Window* pCurrentFrame = _ControlManager::GetInstance()->GetCurrentFrame(); - if (pCurrentFrame == pFrame) - { - if ((__mode == ORIENTATION_AUTOMATIC) || (__mode == ORIENTATION_AUTOMATIC_FOUR_DIRECTION)) - { - pEcoreEvas->SetWindowOrientationEnabled(*pFrame, true); - pFrame->SetOrientationEnabled(true); - } - else - { - pEcoreEvas->SetWindowOrientationEnabled(*pFrame, false); - pFrame->SetOrientationEnabled(false); - } - } - } - } - } - - OrientationStatus status = pImplManager->GetOrientationStatus(__mode); - - if (__updateStatus == true) - { - __statusChanged = false; - if (__status != status) - { - __statusChanged = true; - __updateStatus = false; - } - } - - __status = status; - - pEcoreEvas->AllowSetWindowBounds(false); - FireEvent(status); - pEcoreEvas->AllowSetWindowBounds(true); - - // For the form to be made by Ui-Builder - if ((draw == true) && (__statusChanged == true)) - { - _ControlOrientation coreOrientation = - (status == ORIENTATION_STATUS_PORTRAIT || status == ORIENTATION_STATUS_PORTRAIT_REVERSE) ? - _CONTROL_ORIENTATION_PORTRAIT : _CONTROL_ORIENTATION_LANDSCAPE; - - Rectangle temp; - bool exist = pImpl->GetBuilderBounds(coreOrientation, temp); - if (exist) - { - pImpl->Invalidate(true); - } - } - - // Despite not changing status, it needs to rotate screen. - _ControlImpl* pControlImpl = _ControlImpl::GetInstance(__publicControl); - pImplManager->RotateScreen(pControlImpl, status); -#endif } -#if defined(WINDOW_BASE_ROTATE) void _OrientationAgent::UpdateOrientation(void) { @@ -464,7 +352,6 @@ _OrientationAgent::UpdateOrientation(void) SysLog(NID_UI, "[Window Manager Rotation] ---------- UpdateOrientation : END ----------"); } -#endif void _OrientationAgent::RequestOrientationEvent(void) @@ -527,13 +414,11 @@ _OrientationAgent::FireEvent(OrientationStatus status, bool callback) return; } -#if defined(WINDOW_OWNEE_PREFERRED) _EcoreEvas* pEcoreEvas = GetEcoreEvasMgr()->GetEcoreEvas(); if (!pEcoreEvas) { return; } -#endif _ControlOrientation coreOrientation = (status == ORIENTATION_STATUS_PORTRAIT || status == ORIENTATION_STATUS_PORTRAIT_REVERSE) ? @@ -547,21 +432,6 @@ _OrientationAgent::FireEvent(OrientationStatus status, bool callback) pImplManager->SetOrientationStatus(status); pImpl->GetCore().ChangeLayout(coreOrientation); -#if !defined(WINDOW_BASE_ROTATE) - // Ownee - int owneeCount = pImpl->GetCore().GetOwneeCount(); - for (int i = 0; i < owneeCount; i++) - { - _Window* pOwnee = pImpl->GetCore().GetOwnee(i); - - if (pOwnee) - { - pOwnee->ChangeLayout(coreOrientation); - } - } -#endif - -#if defined(WINDOW_OWNEE_PREFERRED) int owneeCount = pImpl->GetCore().GetOwneeCount(); for (int i = 0; i < owneeCount; i++) { @@ -595,7 +465,6 @@ _OrientationAgent::FireEvent(OrientationStatus status, bool callback) } } } -#endif // Public if (__firePublicEvent && __statusChanged) @@ -607,7 +476,6 @@ _OrientationAgent::FireEvent(OrientationStatus status, bool callback) } } -#if defined(WINDOW_BASE_ROTATE) void _OrientationAgent::SetRotation(const _Window& window, Orientation orientation) { @@ -650,44 +518,6 @@ _OrientationAgent::SetRotation(const _Window& window, Orientation orientation) default: break; } - -#if !defined(WINDOW_OWNEE_PREFERRED) - // [Ownee] - // 1. ActivateWindow - // 2. SetOwner - // 3. SetRotation - - _ControlImpl* pImpl = _ControlImpl::GetInstance(__publicControl); - if (!pImpl) - { - return; - } - - int owneeCount = pImpl->GetCore().GetOwneeCount(); - for (int i = 0; i < owneeCount; i++) - { - _Window* pOwnee = pImpl->GetCore().GetOwnee(i); - if (pOwnee) - { - pEcoreEvas->SetOwner(*pOwnee, pImpl->GetCore()); - } - } - - _Control* pParent = pImpl->GetCore().GetParent(); - if (pParent) - { - int owneeCount = pParent->GetOwneeCount(); - for (int i = 0; i < owneeCount; i++) - { - _Window* pOwnee = pParent->GetOwnee(i); - if (pOwnee) - { - pEcoreEvas->SetOwner(*pOwnee, *pParent); - } - } - } -#endif } -#endif }} // Tizen::Ui diff --git a/src/ui/FUi_OrientationAgent.h b/src/ui/FUi_OrientationAgent.h index b89f0f5..edd99b0 100644 --- a/src/ui/FUi_OrientationAgent.h +++ b/src/ui/FUi_OrientationAgent.h @@ -32,10 +32,7 @@ namespace Tizen { namespace Ui { class _PublicOrientationEvent; - -#if defined(WINDOW_BASE_ROTATE) class _Window; -#endif class _OrientationAgent { @@ -51,10 +48,8 @@ public: void SetMode(Orientation orientation); void Update(bool draw = false); -#if defined(WINDOW_BASE_ROTATE) void UpdateOrientation(void); void SetRotation(const _Window& window, Orientation orientation); -#endif void RequestOrientationEvent(void); void FireOrientationEvent(void); @@ -76,9 +71,7 @@ private: bool __firePublicEvent; bool __statusChanged; bool __updateStatus; -#if defined(WINDOW_BASE_ROTATE) bool __draw; -#endif }; // _OrientationAgent }} // Tizen::Ui diff --git a/src/ui/FUi_Window.cpp b/src/ui/FUi_Window.cpp index ad8dd5e..b017843 100644 --- a/src/ui/FUi_Window.cpp +++ b/src/ui/FUi_Window.cpp @@ -267,12 +267,8 @@ _Window::CreateRootVisualElement(_WindowType windowType) _EcoreEvas* pEcoreEvas = GetEcoreEvasMgr()->GetEcoreEvas(); SysAssert(pEcoreEvas); -#if !defined(WINDOW_BASE_ROTATE) - pEcoreEvas->SetWindowOrientationEnabled(*this, false); -#else __rotation = pEcoreEvas->GetWindowRotation(*this); pEcoreEvas->RegisterWindowStateCallback(*this); -#endif // Get visual element. _VisualElement* pVisualElement = GetVisualElement(); @@ -285,7 +281,6 @@ _Window::CreateRootVisualElement(_WindowType windowType) // Attach visual element to root visual element. __pRootVisualElement->AttachChild(*GetVisualElement()); -#if defined(WINDOW_BASE_ROTATE) if (__type == _WINDOW_TYPE_MAIN) { SysLog(NID_UI, "[Window Manager Rotation][Window : 0x%x, BASIC] Create.", GetNativeHandle()); @@ -295,7 +290,6 @@ _Window::CreateRootVisualElement(_WindowType windowType) pEcoreEvas->SetWindowType(*this, _WINDOW_TYPE_SUB); SysLog(NID_UI, "[Window Manager Rotation][Window : 0x%x, UTILITY] Create.", GetNativeHandle()); } -#endif return E_SUCCESS; } @@ -363,20 +357,6 @@ _Window::IsActivationEnabled(void) return enable; } -#if !defined(WINDOW_BASE_ROTATE) -void -_Window::SetOrientationEnabled(bool enable) -{ - __orientationEnabled = enable; -} - -bool -_Window::IsOrientationEnabled(void) -{ - return __orientationEnabled; -} -#endif - _RootVisualElement* _Window::GetRootVisualElement(void) const { @@ -546,7 +526,6 @@ _Window::OnDetachingFromMainTree(void) return E_SUCCESS; } -#if defined(WINDOW_BASE_ROTATE) void _Window::OnWindowStateChanged(void) { @@ -641,14 +620,11 @@ _Window::GetPreferredRotation(void) const return __preferredRotation; } -#if defined(WINDOW_OWNEE_PREFERRED) bool _Window::IsRotationSynchronized(void) const { return false; } -#endif -#endif bool _Window::IsLayoutChangable(void) const @@ -656,13 +632,11 @@ _Window::IsLayoutChangable(void) const return false; } -#if defined(WINDOW_BASE_ROTATE) void _Window::SetRotation(int rotation) { __rotation = rotation; } -#endif void _Window::OnChangeLayout(_ControlOrientation orientation) @@ -755,16 +729,8 @@ _Window::_Window() , __pFocusedControl(null) , __transient(true) , __dimmingEnabled(false) -#if !defined(WINDOW_BASE_ROTATE) - , __orientationEnabled(false) -#else -#if !defined(WINDOW_OWNEE_PREFERRED) - , __rotation(0) -#else , __rotation(-1) -#endif , __preferredRotation(false) -#endif , __orientationCallbackMode(false) { SetControlDelegate(*this); diff --git a/src/ui/controls/FUiCtrl_ContextMenu.cpp b/src/ui/controls/FUiCtrl_ContextMenu.cpp index 9eb07ce..474e0d9 100644 --- a/src/ui/controls/FUiCtrl_ContextMenu.cpp +++ b/src/ui/controls/FUiCtrl_ContextMenu.cpp @@ -284,9 +284,7 @@ _ContextMenu::OnAttachedToMainTree(void) { result r = E_SUCCESS; -#if defined(WINDOW_BASE_ROTATE) __layout = _ControlManager::GetInstance()->GetOrientation(); -#endif __isAttachedToMainTree = true; _Control* pOwner = GetOwner(); if (pOwner == null) @@ -297,9 +295,6 @@ _ContextMenu::OnAttachedToMainTree(void) _Form* pForm = pFrame->GetCurrentForm(); pForm != null ? SetOwner(pForm) : SetOwner(pFrame); -#if !defined(WINDOW_BASE_ROTATE) - __layout = _ControlManager::GetInstance()->GetOrientation(); -#endif GET_SHAPE_CONFIG(CONTEXTMENU::ITEM_MAX_COUNT, __layout, __showItemMaxCount); } else diff --git a/src/ui/controls/FUiCtrl_FormImpl.cpp b/src/ui/controls/FUiCtrl_FormImpl.cpp index e864d2e..eebc762 100644 --- a/src/ui/controls/FUiCtrl_FormImpl.cpp +++ b/src/ui/controls/FUiCtrl_FormImpl.cpp @@ -1001,7 +1001,6 @@ _FormImpl::UpdateOrientationStatus(bool draw) } } -#if defined(WINDOW_BASE_ROTATE) void _FormImpl::UpdateOrientation(void) { @@ -1010,7 +1009,6 @@ _FormImpl::UpdateOrientation(void) __pOriAgent->UpdateOrientation(); } } -#endif void _FormImpl::UpdateOrientation(int angle) diff --git a/src/ui/controls/FUiCtrl_FrameImpl.cpp b/src/ui/controls/FUiCtrl_FrameImpl.cpp index c36e3fa..dd4e8bb 100644 --- a/src/ui/controls/FUiCtrl_FrameImpl.cpp +++ b/src/ui/controls/FUiCtrl_FrameImpl.cpp @@ -685,7 +685,6 @@ _FrameImpl::UpdateOrientationStatus(void) } } -#if defined(WINDOW_BASE_ROTATE) void _FrameImpl::UpdateOrientation(void) { @@ -694,7 +693,6 @@ _FrameImpl::UpdateOrientation(void) __pOrientationAgent->UpdateOrientation(); } } -#endif void _FrameImpl::UpdateOrientation(int angle) diff --git a/src/ui/inc/FUiCtrl_FormImpl.h b/src/ui/inc/FUiCtrl_FormImpl.h index 14d2a1c..9e11488 100644 --- a/src/ui/inc/FUiCtrl_FormImpl.h +++ b/src/ui/inc/FUiCtrl_FormImpl.h @@ -122,9 +122,7 @@ public: Tizen::Ui::Orientation GetOrientation(void) const; Tizen::Ui::OrientationStatus GetOrientationStatus(void) const; void UpdateOrientationStatus(bool draw = false); -#if defined(WINDOW_BASE_ROTATE) void UpdateOrientation(void); -#endif void UpdateOrientation(int angle); // Invoked by operations diff --git a/src/ui/inc/FUiCtrl_FrameImpl.h b/src/ui/inc/FUiCtrl_FrameImpl.h index a143b29..0242d34 100644 --- a/src/ui/inc/FUiCtrl_FrameImpl.h +++ b/src/ui/inc/FUiCtrl_FrameImpl.h @@ -69,9 +69,7 @@ public: Tizen::Ui::OrientationStatus GetOrientationStatus(void) const; void SetOrientation(Tizen::Ui::Orientation orientation); void UpdateOrientationStatus(void); -#if defined(WINDOW_BASE_ROTATE) void UpdateOrientation(void); -#endif void UpdateOrientation(int angle); // Callback diff --git a/src/ui/inc/FUi_EcoreEvas.h b/src/ui/inc/FUi_EcoreEvas.h index bdbe44e..7762ba1 100644 --- a/src/ui/inc/FUi_EcoreEvas.h +++ b/src/ui/inc/FUi_EcoreEvas.h @@ -110,15 +110,11 @@ public: void RotateWindow(const _Window& window, int orientation, bool rotateEvas = true); int GetWindowRotation(const _Window& window); -#if defined(WINDOW_BASE_ROTATE) void SetWindowPreferredRotation(const _Window& window, int rotation); void SetWindowAvailabledRotation(const _Window& window, int* rotations, unsigned int count); void RegisterWindowStateCallback(const _Window& window); void SetWindowRotationBounds(const _Window& window, int rotation, const Tizen::Graphics::Rectangle& bounds); void SetWindowRotationBounds(const _Window& window, int rotation, const Tizen::Graphics::FloatRectangle& bounds); -#else - void SetWindowOrientationEnabled(const _Window& window, bool enable); -#endif void SetWindowType(const _Window& window, int winType); result SetFloatingMode(const _Window& window, bool enable); diff --git a/src/ui/inc/FUi_Types.h b/src/ui/inc/FUi_Types.h index 999d474..00b4ace 100644 --- a/src/ui/inc/FUi_Types.h +++ b/src/ui/inc/FUi_Types.h @@ -23,10 +23,6 @@ #include #include -#define MULTI_WINDOW -#define WINDOW_BASE_ROTATE -#define WINDOW_OWNEE_PREFERRED - namespace Tizen { namespace Ui { diff --git a/src/ui/inc/FUi_Window.h b/src/ui/inc/FUi_Window.h index 89e2b65..aad7128 100644 --- a/src/ui/inc/FUi_Window.h +++ b/src/ui/inc/FUi_Window.h @@ -81,9 +81,7 @@ public: virtual result CreateLayer(void); virtual bool IsFocusableDescendant(const _Control* pFocus) const; virtual bool IsLayoutChangable(void) const; -#if defined(WINDOW_BASE_ROTATE) void SetRotation(int rotation); -#endif // Focus _Control* GetFocusedControl(void) const; @@ -99,17 +97,10 @@ public: virtual result OnAttachingToMainTree(const _Control* pParent); virtual result OnDetachingFromMainTree(void); virtual void OnFocusableStateChanged(bool focusalbeState); -#if defined(WINDOW_BASE_ROTATE) virtual void OnWindowStateChanged(void); void SetPreferredRotation(bool enable); bool GetPreferredRotation(void) const; -#if defined(WINDOW_OWNEE_PREFERRED) virtual bool IsRotationSynchronized(void) const; -#endif -#else - void SetOrientationEnabled(bool enable); - bool IsOrientationEnabled(void); -#endif void SetActivationEnabled(bool enable); bool IsActivationEnabled(void); @@ -179,13 +170,8 @@ private: //For Focus UI mutable std::unique_ptr > __pFocusControlList; -#if !defined(WINDOW_BASE_ROTATE) - bool __orientationEnabled; -#else int __rotation; bool __preferredRotation; -#endif - bool __orientationCallbackMode; friend class _ControlManager; -- 2.7.4