2 * Copyright (c) 2014 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
22 #include <dali/integration-api/debug.h>
25 #include <accessibility-manager.h>
26 #include <imf-manager.h>
27 #include <style-monitor.h>
29 #include <adaptor-impl.h>
30 #include <render-surface-impl.h>
31 #include <window-impl.h>
36 Adaptor& Adaptor::New( Window window )
38 return New( window, DeviceLayout::DEFAULT_BASE_LAYOUT, Configuration::APPLICATION_DOES_NOT_HANDLE_CONTEXT_LOSS );
41 Adaptor& Adaptor::New( Window window, const DeviceLayout& baseLayout, Configuration::ContextLoss configuration )
43 Internal::Adaptor::Window& windowImpl = GetImplementation(window);
44 Adaptor* adaptor = Internal::Adaptor::Adaptor::New( windowImpl.GetSurface(), baseLayout, configuration );
45 windowImpl.SetAdaptor(*adaptor);
64 void Adaptor::Resume()
74 bool Adaptor::AddIdle( CallbackBase* callback )
76 return mImpl->AddIdle( callback );
79 Adaptor::AdaptorSignalType& Adaptor::ResizedSignal()
81 return mImpl->ResizedSignal();
84 Adaptor::AdaptorSignalType& Adaptor::LanguageChangedSignal()
86 return mImpl->LanguageChangedSignal();
89 RenderSurface& Adaptor::GetSurface()
91 return mImpl->GetSurface();
94 void Adaptor::ReleaseSurfaceLock()
96 mImpl->ReleaseSurfaceLock();
99 void Adaptor::SetRenderRefreshRate( unsigned int numberOfVSyncsPerRender )
101 mImpl->SetRenderRefreshRate( numberOfVSyncsPerRender );
104 void Adaptor::SetUseHardwareVSync(bool useHardware)
106 mImpl->SetUseHardwareVSync( useHardware );
109 Adaptor& Adaptor::Get()
111 return Internal::Adaptor::Adaptor::Get();
114 bool Adaptor::IsAvailable()
116 return Internal::Adaptor::Adaptor::IsAvailable();
119 void Adaptor::NotifyLanguageChanged()
121 mImpl->NotifyLanguageChanged();
124 void Adaptor::SetMinimumPinchDistance(float distance)
126 mImpl->SetMinimumPinchDistance(distance);