1 #ifndef DALI_INTERNAL_WINDOWSYSTEM_COMMON_WINDOW_BASE_H
2 #define DALI_INTERNAL_WINDOWSYSTEM_COMMON_WINDOW_BASE_H
5 * Copyright (c) 2018 Samsung Electronics Co., Ltd.
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
22 #include <dali/public-api/adaptor-framework/window.h>
23 #include <dali/public-api/adaptor-framework/key-grab.h>
24 #include <dali/internal/window-system/common/indicator-interface.h>
38 * WindowBase interface
45 * @brief Default constructor
47 WindowBase() = default;
52 virtual ~WindowBase() = default;
57 * Second stage initialization
59 virtual void Initialize() = 0;
62 * @copydoc Dali::Window::ShowIndicator()
64 virtual void ShowIndicator( Dali::Window::IndicatorVisibleMode visibleMode, Dali::Window::IndicatorBgOpacity opacityMode ) = 0;
67 * Set the indicator properties on the window
69 virtual void SetIndicatorProperties( bool isShow, Dali::Window::WindowOrientation lastOrientation ) = 0;
72 * @copydoc Dali::Internal::Adaptor::IndicatorInterface::Observer::IndicatorTypeChanged()
74 virtual void IndicatorTypeChanged( IndicatorInterface::Type type ) = 0;
77 * @copydoc Dali::Window::SetClass()
79 virtual void SetClass( std::string name, std::string className ) = 0;
82 * @copydoc Dali::Window::Raise()
84 virtual void Raise() = 0;
87 * @copydoc Dali::Window::Lower()
89 virtual void Lower() = 0;
92 * @copydoc Dali::Window::Activate()
94 virtual void Activate() = 0;
97 * @copydoc Dali::Window::SetAvailableOrientations()
99 virtual void SetAvailableOrientations( const std::vector< Dali::Window::WindowOrientation >& orientations ) = 0;
102 * @copydoc Dali::Window::SetPreferredOrientation()
104 virtual void SetPreferredOrientation( Dali::Window::WindowOrientation orientation ) = 0;
107 * @copydoc Dali::Window::SetAcceptFocus()
109 virtual void SetAcceptFocus( bool accept ) = 0;
112 * @copydoc Dali::Window::Show()
114 virtual void Show() = 0;
117 * @copydoc Dali::Window::Hide()
119 virtual void Hide() = 0;
122 * @copydoc Dali::Window::GetSupportedAuxiliaryHintCount()
124 virtual unsigned int GetSupportedAuxiliaryHintCount() const = 0;
127 * @copydoc Dali::Window::GetSupportedAuxiliaryHint()
129 virtual std::string GetSupportedAuxiliaryHint( unsigned int index ) const = 0;
132 * @copydoc Dali::Window::AddAuxiliaryHint()
134 virtual unsigned int AddAuxiliaryHint( const std::string& hint, const std::string& value ) = 0;
137 * @copydoc Dali::Window::RemoveAuxiliaryHint()
139 virtual bool RemoveAuxiliaryHint( unsigned int id ) = 0;
142 * @copydoc Dali::Window::SetAuxiliaryHintValue()
144 virtual bool SetAuxiliaryHintValue( unsigned int id, const std::string& value ) = 0;
147 * @copydoc Dali::Window::GetAuxiliaryHintValue()
149 virtual std::string GetAuxiliaryHintValue( unsigned int id ) const = 0;
152 * @copydoc Dali::Window::GetAuxiliaryHintId()
154 virtual unsigned int GetAuxiliaryHintId( const std::string& hint ) const = 0;
157 * @copydoc Dali::Window::SetInputRegion()
159 virtual void SetInputRegion( const Rect< int >& inputRegion ) = 0;
162 * @copydoc Dali::Window::SetType()
164 virtual void SetType( Dali::Window::Type type ) = 0;
167 * @copydoc Dali::Window::SetNotificationLevel()
169 virtual bool SetNotificationLevel( Dali::Window::NotificationLevel::Type level ) = 0;
172 * @copydoc Dali::Window::GetNotificationLevel()
174 virtual Dali::Window::NotificationLevel::Type GetNotificationLevel() const = 0;
177 * @copydoc Dali::Window::SetOpaqueState()
179 virtual void SetOpaqueState( bool opaque ) = 0;
182 * @copydoc Dali::Window::SetScreenOffMode()
184 virtual bool SetScreenOffMode(Dali::Window::ScreenOffMode::Type screenOffMode) = 0;
187 * @copydoc Dali::Window::GetScreenOffMode()
189 virtual Dali::Window::ScreenOffMode::Type GetScreenOffMode() const = 0;
192 * @copydoc Dali::Window::SetBrightness()
194 virtual bool SetBrightness( int brightness ) = 0;
197 * @copydoc Dali::Window::GetBrightness()
199 virtual int GetBrightness() const = 0;
202 * @copydoc Dali::KeyGrab::GrabKey()
204 virtual bool GrabKey( Dali::KEY key, KeyGrab::KeyGrabMode grabMode ) = 0;
207 * @copydoc Dali::KeyGrab::UngrabKey()
209 virtual bool UngrabKey( Dali::KEY key ) = 0;
212 * @copydoc Dali::KeyGrab::GrabKeyList()
214 virtual bool GrabKeyList( const Dali::Vector< Dali::KEY >& key, const Dali::Vector< KeyGrab::KeyGrabMode >& grabMode, Dali::Vector< bool >& result ) = 0;
217 * @copydoc Dali::KeyGrab::UngrabKeyList()
219 virtual bool UngrabKeyList( const Dali::Vector< Dali::KEY >& key, Dali::Vector< bool >& result ) = 0;
224 WindowBase(const WindowBase&) = delete;
227 WindowBase& operator=(const WindowBase& rhs) = delete;
231 } // namespace Adaptor
233 } // namespace internal
237 #endif // DALI_INTERNAL_WINDOWSYSTEM_COMMON_WINDOW_BASE_H