From 007c55dce4aef2975b037c985563a63e94374b71 Mon Sep 17 00:00:00 2001 From: Sunghyun kim Date: Mon, 13 May 2019 19:00:22 +0900 Subject: [PATCH] [Tizen] Temporarily revert new APIs for Multi-window This reverts commit 308180d6f2f1669b8abb740d9aabe719fca47b36. Change-Id: I6de368f84a1df0f52ab15200586493113dcfa04a --- dali/devel-api/adaptor-framework/window-devel.cpp | 35 +++++++++++ dali/devel-api/adaptor-framework/window-devel.h | 64 +++++++++++++++++++ dali/integration-api/scene-holder-impl.cpp | 2 +- dali/integration-api/scene-holder-impl.h | 2 +- dali/internal/window-system/common/window-impl.cpp | 2 +- dali/internal/window-system/common/window-impl.h | 4 +- dali/public-api/adaptor-framework/window.cpp | 37 +---------- dali/public-api/adaptor-framework/window.h | 72 +--------------------- 8 files changed, 107 insertions(+), 111 deletions(-) diff --git a/dali/devel-api/adaptor-framework/window-devel.cpp b/dali/devel-api/adaptor-framework/window-devel.cpp index 2496c21..0857885 100644 --- a/dali/devel-api/adaptor-framework/window-devel.cpp +++ b/dali/devel-api/adaptor-framework/window-devel.cpp @@ -40,6 +40,41 @@ Window Get( Actor actor ) return Internal::Adaptor::Window::Get( actor ); } +void Add( Window window, Dali::Actor actor ) +{ + GetImplementation( window ).Add( actor ); +} + +void Remove( Window window, Dali::Actor actor ) +{ + GetImplementation( window ).Remove( actor ); +} + +void SetBackgroundColor( Window window, Vector4 color ) +{ + GetImplementation( window ).SetBackgroundColor( color ); +} + +Vector4 GetBackgroundColor( Window window ) +{ + return GetImplementation( window ).GetBackgroundColor(); +} + +Dali::Layer GetRootLayer( Window window ) +{ + return GetImplementation( window ).GetRootLayer(); +} + +uint32_t GetLayerCount( Window window ) +{ + return GetImplementation( window ).GetLayerCount(); +} + +Dali::Layer GetLayer( Window window, uint32_t depth ) +{ + return GetImplementation( window ).GetLayer( depth ); +} + EventProcessingFinishedSignalType& EventProcessingFinishedSignal( Window window ) { return GetImplementation( window ).EventProcessingFinishedSignal(); diff --git a/dali/devel-api/adaptor-framework/window-devel.h b/dali/devel-api/adaptor-framework/window-devel.h index e80e55a..8655506 100644 --- a/dali/devel-api/adaptor-framework/window-devel.h +++ b/dali/devel-api/adaptor-framework/window-devel.h @@ -55,6 +55,70 @@ DALI_ADAPTOR_API void SetPositionSize( Window window, PositionSize positionSize DALI_ADAPTOR_API Window Get( Actor actor ); /** + * @brief Adds a child Actor to the Window. + * + * The child will be referenced. + * @param[in] window The window instance + * @param[in] actor The child + * @pre The actor has been initialized. + * @pre The actor does not have a parent. + */ +DALI_ADAPTOR_API void Add( Window window, Dali::Actor actor ); + +/** + * @brief Removes a child Actor from the Window. + * + * The child will be unreferenced. + * @param[in] window The window instance + * @param[in] actor The child + * @pre The actor has been added to the stage. + */ +DALI_ADAPTOR_API void Remove( Window window, Dali::Actor actor ); + +/** + * @brief Sets the background color of the window. + * + * @param[in] window The window instance + * @param[in] color The new background color + */ +DALI_ADAPTOR_API void SetBackgroundColor( Window window, Vector4 color ); + +/** + * @brief Gets the background color of the surface. + * + * @param[in] window The window instance + * @return The background color + */ +DALI_ADAPTOR_API Vector4 GetBackgroundColor( Window window ); + +/** + * @brief Returns the Scene's Root Layer. + * + * @param[in] window The window instance + * @return The root layer + */ +DALI_ADAPTOR_API Dali::Layer GetRootLayer( Window window ); + +/** + * @brief Queries the number of on-stage layers. + * + * Note that a default layer is always provided (count >= 1). + * @param[in] window The window instance + * @return The number of layers + */ +DALI_ADAPTOR_API uint32_t GetLayerCount( Window window ); + +/** + * @brief Retrieves the layer at a specified depth. + * + * @param[in] window The window instance + * @param[in] depth The depth + * @return The layer found at the given depth + * @pre Depth is less than layer count; see GetLayerCount(). + */ +DALI_ADAPTOR_API Dali::Layer GetLayer( Window window, uint32_t depth ); + +/** * @brief This signal is emitted just after the event processing is finished. * * @param[in] window The window instance diff --git a/dali/integration-api/scene-holder-impl.cpp b/dali/integration-api/scene-holder-impl.cpp index efa8291..e085ed3 100644 --- a/dali/integration-api/scene-holder-impl.cpp +++ b/dali/integration-api/scene-holder-impl.cpp @@ -144,7 +144,7 @@ Dali::RenderSurfaceInterface* SceneHolder::GetSurface() const return mSurface.get(); } -void SceneHolder::SetBackgroundColor( const Vector4& color ) +void SceneHolder::SetBackgroundColor( Vector4 color ) { if ( mSurface ) { diff --git a/dali/integration-api/scene-holder-impl.h b/dali/integration-api/scene-holder-impl.h index 6b283ad..d720f7f 100644 --- a/dali/integration-api/scene-holder-impl.h +++ b/dali/integration-api/scene-holder-impl.h @@ -124,7 +124,7 @@ public: /** * @copydoc Dali::Integration::SceneHolder::SetBackgroundColor */ - void SetBackgroundColor( const Dali::Vector4& color ); + void SetBackgroundColor( Dali::Vector4 color ); /** * @copydoc Dali::Integration::SceneHolder::GetBackgroundColor diff --git a/dali/internal/window-system/common/window-impl.cpp b/dali/internal/window-system/common/window-impl.cpp index 443f86a..0a58f84 100644 --- a/dali/internal/window-system/common/window-impl.cpp +++ b/dali/internal/window-system/common/window-impl.cpp @@ -507,7 +507,7 @@ void Window::SetPositionSize( PositionSize positionSize ) } } -Dali::Layer Window::GetRootLayer() const +Dali::Layer Window::GetRootLayer() { return mScene.GetRootLayer(); } diff --git a/dali/internal/window-system/common/window-impl.h b/dali/internal/window-system/common/window-impl.h index 1249b3e..8abcd13 100644 --- a/dali/internal/window-system/common/window-impl.h +++ b/dali/internal/window-system/common/window-impl.h @@ -294,9 +294,9 @@ public: void SetPositionSize( PositionSize positionSize ); /** - * @copydoc Dali::Window::GetRootLayer() + * @copydoc Dali::DevelWindow::GetRootLayer() */ - Dali::Layer GetRootLayer() const; + Dali::Layer GetRootLayer(); /** * @copydoc Dali::Window::SetTransparency() diff --git a/dali/public-api/adaptor-framework/window.cpp b/dali/public-api/adaptor-framework/window.cpp index 2e6a28c..34a8fa9 100644 --- a/dali/public-api/adaptor-framework/window.cpp +++ b/dali/public-api/adaptor-framework/window.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019 Samsung Electronics Co., Ltd. + * Copyright (c) 2017 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -72,41 +72,6 @@ Window& Window::operator=(const Window& rhs) return *this; } -void Window::Add( Dali::Actor actor ) -{ - GetImplementation( *this ).Add( actor ); -} - -void Window::Remove( Dali::Actor actor ) -{ - GetImplementation( *this ).Remove( actor ); -} - -void Window::SetBackgroundColor( const Vector4& color ) -{ - GetImplementation( *this ).SetBackgroundColor( color ); -} - -Vector4 Window::GetBackgroundColor() const -{ - return GetImplementation( *this ).GetBackgroundColor(); -} - -Layer Window::GetRootLayer() const -{ - return GetImplementation( *this ).GetRootLayer(); -} - -uint32_t Window::GetLayerCount() const -{ - return GetImplementation( *this ).GetLayerCount(); -} - -Layer Window::GetLayer( uint32_t depth ) const -{ - return GetImplementation( *this ).GetLayer( depth ); -} - void Window::ShowIndicator( IndicatorVisibleMode visibleMode ) { DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: ShowIndicator is deprecated and will be removed from next release.\n" ); diff --git a/dali/public-api/adaptor-framework/window.h b/dali/public-api/adaptor-framework/window.h index 0d559c1..0591d25 100755 --- a/dali/public-api/adaptor-framework/window.h +++ b/dali/public-api/adaptor-framework/window.h @@ -2,7 +2,7 @@ #define DALI_WINDOW_H /* - * Copyright (c) 2019 Samsung Electronics Co., Ltd. + * Copyright (c) 2018 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -222,73 +222,6 @@ public: Window& operator=(const Window& rhs); /** - * @brief Adds a child Actor to the Window. - * - * The child will be referenced. - * - * @SINCE_1_4.19 - * @param[in] actor The child - * @pre The actor has been initialized. - * @pre The actor does not have a parent. - */ - void Add( Actor actor ); - - /** - * @brief Removes a child Actor from the Window. - * - * The child will be unreferenced. - * - * @SINCE_1_4.19 - * @param[in] actor The child - * @pre The actor has been added to the stage. - */ - void Remove( Actor actor ); - - /** - * @brief Sets the background color of the Window. - * - * @SINCE_1_4.19 - * @param[in] color The new background color - */ - void SetBackgroundColor( const Vector4& color ); - - /** - * @brief Gets the background color of the Window. - * - * @SINCE_1_4.19 - * @return The background color - */ - Vector4 GetBackgroundColor() const; - - /** - * @brief Returns the root Layer of the Window. - * - * @SINCE_1_4.19 - * @return The root layer - */ - Layer GetRootLayer() const; - - /** - * @brief Queries the number of on-scene layers in the Window. - * - * Note that a default layer is always provided (count >= 1). - * - * @SINCE_1_4.19 - * @return The number of layers - */ - uint32_t GetLayerCount() const; - - /** - * @brief Retrieves the layer at a specified depth in the Window. - * - * @SINCE_1_4.19 - * @param[in] depth The depth - * @return The layer found at the given depth - * @pre Depth is less than layer count; see GetLayerCount(). - */ - Layer GetLayer( uint32_t depth ) const; - - /** * @DEPRECATED_1_4.9 * @brief This sets whether the indicator bar should be shown or not. * @SINCE_1_0.0 @@ -370,13 +303,12 @@ public: WindowOrientation GetPreferredOrientation(); /** - * @DEPRECATED_1_4.19 Was not intended for Application developers * @brief Returns an empty handle. * @note Not intended for application developers. * @SINCE_1_0.0 * @return An empty handle */ - DragAndDropDetector GetDragAndDropDetector() const DALI_DEPRECATED_API; + DragAndDropDetector GetDragAndDropDetector() const; /** * @brief Gets the native handle of the window. -- 2.7.4