Merge "[Tizen][AT-SPI] Rework intercepting key events" into tizen
[platform/core/uifw/dali-adaptor.git] / dali / internal / adaptor / common / adaptor-impl.h
1 #ifndef DALI_INTERNAL_ADAPTOR_IMPL_H
2 #define DALI_INTERNAL_ADAPTOR_IMPL_H
3
4 /*
5  * Copyright (c) 2023 Samsung Electronics Co., Ltd.
6  *
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
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
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.
18  *
19  */
20
21 // EXTERNAL INCLUDES
22 #include <dali/devel-api/threading/mutex.h>
23 #include <dali/integration-api/render-controller.h>
24 #include <dali/public-api/adaptor-framework/timer.h>
25 #include <dali/public-api/common/vector-wrapper.h>
26 #include <dali/public-api/math/rect.h>
27 #include <dali/public-api/math/uint-16-pair.h>
28 #include <dali/public-api/signals/callback.h>
29
30 // INTERNAL INCLUDES
31 #include <dali/integration-api/adaptor-framework/adaptor.h>
32 #include <dali/integration-api/adaptor-framework/scene-holder-impl.h>
33 #include <dali/integration-api/adaptor-framework/trigger-event-factory.h>
34 #include <dali/integration-api/scene.h>
35 #include <dali/internal/adaptor/common/adaptor-internal-services.h>
36 #include <dali/internal/graphics/common/graphics-interface.h>
37 #include <dali/internal/legacy/common/tizen-platform-abstraction.h>
38 #include <dali/internal/network/common/socket-factory.h>
39 #include <dali/internal/system/common/core-event-interface.h>
40 #include <dali/internal/system/common/environment-options.h>
41 #include <dali/internal/system/common/kernel-trace.h>
42 #include <dali/internal/system/common/system-trace.h>
43 #include <dali/internal/window-system/common/damage-observer.h>
44 #include <dali/internal/window-system/common/window-visibility-observer.h>
45 #include <dali/public-api/adaptor-framework/tts-player.h>
46
47 #include <string>
48
49 namespace Dali
50 {
51 class RenderSurfaceInterface;
52
53 namespace Integration
54 {
55 class Core;
56 class GlAbstraction;
57 class Processor;
58 class AddOnManager;
59 } // namespace Integration
60
61 namespace Internal
62 {
63 namespace Adaptor
64 {
65 class DisplayConnection;
66 class GraphicsFactory;
67 class GlImplementation;
68 class GlSyncImplementation;
69 class ThreadController;
70 class TriggerEvent;
71 class CallbackManager;
72 class FeedbackPluginProxy;
73 class FeedbackController;
74 class VSyncMonitor;
75 class PerformanceInterface;
76 class LifeCycleObserver;
77 class ObjectProfiler;
78 class SceneHolder;
79 class ConfigurationManager;
80 enum class ThreadMode;
81
82 /**
83  * Implementation of the Adaptor class.
84  */
85 class Adaptor : public Integration::RenderController,
86                 public AdaptorInternalServices,
87                 public CoreEventInterface,
88                 public DamageObserver,
89                 public WindowVisibilityObserver
90 {
91 public:
92   using AdaptorSignalType       = Dali::Adaptor::AdaptorSignalType;
93   using WindowCreatedSignalType = Dali::Adaptor::WindowCreatedSignalType;
94   using LocaleChangedSignalType = Dali::Adaptor::LocaleChangedSignalType;
95
96   using SurfaceSize = Uint16Pair; ///< Surface size type
97
98   /**
99    * Creates a New Adaptor
100    * @param[in]  window              The window handle
101    * @param[in]  surface             A render surface can be one of the following
102    *                                  - Pixmap, adaptor will use existing Pixmap to draw on to
103    *                                  - Window, adaptor will use existing Window to draw on to
104    * @param[in]  environmentOptions  A pointer to the environment options. If NULL then one is created.
105    * @param[in]  threadMode          The thread mode
106    */
107   static Dali::Adaptor* New(Dali::Integration::SceneHolder window,
108                             Dali::RenderSurfaceInterface*  surface,
109                             EnvironmentOptions*            environmentOptions,
110                             ThreadMode                     threadMode);
111
112   /**
113    * Creates a New Adaptor
114    * @param[in]  window              The window handle
115    * @param[in]  environmentOptions  A pointer to the environment options. If NULL then one is created.
116    */
117   static Dali::Adaptor* New(Dali::Integration::SceneHolder window,
118                             EnvironmentOptions*            environmentOptions);
119
120   /**
121    * Creates a New Adaptor
122    * @param[in]  graphicsFactory     A factory that creates the graphics interface
123    * @param[in]  window              The window handle
124    * @param[in]  surface             A render surface can be one of the following
125    *                                  - Pixmap, adaptor will use existing Pixmap to draw on to
126    *                                  - Window, adaptor will use existing Window to draw on to
127    * @param[in]  environmentOptions  A pointer to the environment options. If NULL then one is created.
128    * @param[in]  threadMode          The thread mode
129    */
130   static Dali::Adaptor* New(GraphicsFactory&               graphicsFactory,
131                             Dali::Integration::SceneHolder window,
132                             Dali::RenderSurfaceInterface*  surface,
133                             EnvironmentOptions*            environmentOptions,
134                             ThreadMode                     threadMode);
135
136   /**
137    * Creates a New Adaptor
138    * @param[in]  graphicsFactory     A factory that creates the graphics interface
139    * @param[in]  window              The window handle
140    * @param[in]  environmentOptions  A pointer to the environment options. If NULL then one is created.
141    */
142   static Dali::Adaptor* New(GraphicsFactory&               graphicsFactory,
143                             Dali::Integration::SceneHolder window,
144                             EnvironmentOptions*            environmentOptions);
145
146   /**
147    * 2-step initialisation, this should be called after creating an adaptor instance.
148    * @param[in]  graphicsFactory     A factory that creates the graphics interface
149    */
150   void Initialize(GraphicsFactory& graphicsFactory);
151
152   /**
153    * Virtual destructor.
154    */
155   ~Adaptor() override;
156
157   /**
158    * @copydoc Dali::Adaptor::Get()
159    */
160   static Dali::Adaptor& Get();
161
162   /**
163    * @copydoc Dali::Adaptor::IsAvailable()
164    */
165   static bool IsAvailable();
166
167   /**
168    * @copydoc Dali::Core::SceneCreated();
169    */
170   void SceneCreated();
171
172   /**
173    * Get the application package name
174    */
175   static std::string GetApplicationPackageName();
176
177 public: // AdaptorInternalServices implementation
178   /**
179    * @copydoc Dali::Adaptor::Start()
180    */
181   virtual void Start();
182
183   /**
184    * @copydoc Dali::Adaptor::Pause()
185    */
186   virtual void Pause();
187
188   /**
189    * @copydoc Dali::Adaptor::Resume()
190    */
191   virtual void Resume();
192
193   /**
194    * @copydoc Dali::Adaptor::Stop()
195    */
196   virtual void Stop();
197
198   /**
199    * @copydoc Dali::Adaptor::ContextLost()
200    */
201   virtual void ContextLost();
202
203   /**
204    * @copydoc Dali::Adaptor::ContextRegained()
205    */
206   virtual void ContextRegained();
207
208   /**
209    * @copydoc Dali::EventFeeder::FeedTouchPoint()
210    */
211   virtual void FeedTouchPoint(TouchPoint& point, int timeStamp);
212
213   /**
214    * @copydoc Dali::EventFeeder::FeedWheelEvent()
215    */
216   virtual void FeedWheelEvent(Dali::WheelEvent& wheelEvent);
217
218   /**
219    * @copydoc Dali::EventFeeder::FeedKeyEvent()
220    */
221   virtual void FeedKeyEvent(Dali::KeyEvent& keyEvent);
222
223   /**
224    * @copydoc Dali::Adaptor::ReplaceSurface()
225    */
226   virtual void ReplaceSurface(Dali::Integration::SceneHolder window, Dali::RenderSurfaceInterface& surface);
227
228   /**
229    * @copydoc Dali::Adaptor::GetSurface()
230    */
231   virtual Dali::RenderSurfaceInterface& GetSurface() const;
232
233   /**
234    * @copydoc Dali::Adaptor::ReleaseSurfaceLock()
235    */
236   virtual void ReleaseSurfaceLock();
237
238   /**
239    * Retrieve the TtsPlayer.
240    * @param[in] mode The mode of TtsPlayer
241    * @return A handle to the TtsPlayer.
242    */
243   virtual Dali::TtsPlayer GetTtsPlayer(Dali::TtsPlayer::Mode mode);
244
245   /**
246    * @copydoc Dali::Adaptor::AddIdle()
247    */
248   virtual bool AddIdle(CallbackBase* callback, bool hasReturnValue);
249
250   /**
251    * Adds a new Window instance to the Adaptor
252    * @param[in]  childWindow The child window instance
253    */
254   virtual bool AddWindow(Dali::Integration::SceneHolder childWindow);
255
256   /**
257    * Removes an existing Window instance from the Adaptor
258    * @param[in]  window The Window instance
259    */
260   virtual bool RemoveWindow(Dali::Integration::SceneHolder* childWindow);
261
262   /**
263    * Removes an existing Window instance from the Adaptor
264    * @param[in]  windowName The Window name
265    * @note If two Windows have the same name, the first one that matches will be removed
266    */
267   virtual bool RemoveWindow(std::string childWindowName);
268
269   /**
270    * @copydoc Dali::Adaptor::RemoveIdle()
271    */
272   virtual void RemoveIdle(CallbackBase* callback);
273
274   /**
275    * @copydoc Dali::Adaptor::ProcessIdle()
276    */
277   virtual void ProcessIdle();
278
279   /**
280    * Sets a pre-render callback.
281    */
282   void SetPreRenderCallback(CallbackBase* callback);
283
284   /**
285    * Removes an existing Window instance from the Adaptor
286    * @param[in]  childWindow The Window instance
287    */
288   bool RemoveWindow(Dali::Internal::Adaptor::SceneHolder* childWindow);
289
290   /**
291    * @brief Deletes the rendering surface
292    * @param[in] surface to delete
293    */
294   void DeleteSurface(Dali::RenderSurfaceInterface& surface);
295
296   /**
297    * @brief Retrieve the window that the given actor is added to.
298    *
299    * @param[in] actor The actor
300    * @return The window the actor is added to or a null pointer if the actor is not added to any widnow.
301    */
302   Dali::Internal::Adaptor::SceneHolder* GetWindow(Dali::Actor& actor);
303
304   /**
305    * @copydoc Dali::Adaptor::GetWindows()
306    */
307   Dali::WindowContainer GetWindows() const;
308
309   /**
310    * @copydoc Dali::Adaptor::GetSceneHolders()
311    */
312   Dali::SceneHolderList GetSceneHolders() const;
313
314   /**
315    * @copydoc Dali::Adaptor::GetObjectRegistry()
316    */
317   Dali::ObjectRegistry GetObjectRegistry() const;
318
319 public:
320   /**
321    * @return the Core instance
322    */
323   Dali::Integration::Core& GetCore() override;
324
325   /**
326    * @copydoc Dali::Adaptor::SetRenderRefreshRate()
327    */
328   void SetRenderRefreshRate(unsigned int numberOfVSyncsPerRender);
329
330   /**
331    * Return the PlatformAbstraction.
332    * @return The PlatformAbstraction.
333    */
334   Integration::PlatformAbstraction& GetPlatformAbstraction() const;
335
336   /**
337    * Destroy the TtsPlayer of specific mode.
338    * @param[in] mode The mode of TtsPlayer to destroy
339    */
340   void DestroyTtsPlayer(Dali::TtsPlayer::Mode mode);
341
342   /**
343    * Gets native window handle
344    *
345    * @return native window handle
346    */
347   Any GetNativeWindowHandle();
348
349   /**
350    * @brief Retrieve native window handle that the given actor is added to.
351    *
352    * @param[in] actor The actor
353    * @return native window handle
354    */
355   Any GetNativeWindowHandle(Dali::Actor actor);
356
357   /**
358    * Get the native display associated with the graphics backend
359    *
360    * @return A handle to the native display
361    */
362   Any GetGraphicsDisplay();
363
364   /**
365    * Sets use remote surface for Surface output
366    * @param[in] useRemoteSurface True if the remote surface is used
367    */
368   void SetUseRemoteSurface(bool useRemoteSurface);
369
370 public:
371   /**
372    * Adds an adaptor observer so that we can observe the adaptor's lifetime events.
373    * @param[in]  observer  The observer.
374    * @note Observers should remove themselves when they are destroyed.
375    */
376   void AddObserver(LifeCycleObserver& observer);
377
378   /**
379    * Removes the observer from the adaptor.
380    * @param[in]  observer  The observer to remove.
381    * @note Observers should remove themselves when they are destroyed.
382    */
383   void RemoveObserver(LifeCycleObserver& observer);
384
385   /**
386    * Emits the Notification event to the Dali core.
387    */
388   void SendNotificationEvent();
389
390   /**
391    * Request adaptor to update once
392    */
393   void RequestUpdateOnce();
394
395   /**
396    * @copydoc Dali::Adaptor::NotifySceneCreated()
397    */
398   void NotifySceneCreated();
399
400   /**
401    * @copydoc Dali::Adaptor::NotifyLanguageChanged()
402    */
403   void NotifyLanguageChanged();
404
405   /**
406    * Gets AppId of current application
407    */
408   void GetAppId(std::string& appId);
409
410   /**
411    * Gets path for resource storage.
412    * @param[out] path Path for resource storage
413    */
414   void GetResourceStoragePath(std::string& path);
415
416   /**
417    * @copydoc Dali::Adaptor::SurfaceResizePrepare
418    */
419   void SurfaceResizePrepare(Dali::RenderSurfaceInterface* surface, SurfaceSize surfaceSize);
420
421   /**
422    * @copydoc Dali::Adaptor::SurfaceResizeComplete
423    */
424   void SurfaceResizeComplete(Dali::RenderSurfaceInterface* surface, SurfaceSize surfaceSize);
425
426   /**
427    * @brief Increase surface resize completed counter.
428    * This API will be ignored if thread controller is not exist.
429    */
430   void IncreaseSurfaceResizeCounter();
431
432   /**
433    * Sets layout direction of root by system language
434    * @param[in] locale System locale
435    */
436   void SetRootLayoutDirection(std::string locale);
437
438   /**
439    * @copydoc Dali::Adaptor::RenderOnce
440    */
441   void RenderOnce();
442
443   /**
444    * @copydoc Dali::Adaptor::GetLogFactory
445    */
446   const LogFactoryInterface& GetLogFactory();
447
448   /**
449    * @copydoc Dali::Adaptor::GetTraceFactory
450    */
451   const TraceFactoryInterface& GetTraceFactory();
452
453   /**
454    * @copydoc Dali::Adaptor::RegisterProcessor
455    */
456   void RegisterProcessor(Integration::Processor& processor, bool postProcessor);
457
458   /**
459    * @coydoc Dali::Adaptor::UnregisterProcessor
460    */
461   void UnregisterProcessor(Integration::Processor& processor, bool postProcessor);
462
463   /**
464    * Check MultipleWindow is supported
465    */
466   bool IsMultipleWindowSupported() const;
467
468   /**
469    * @brief Gets the render thread id of DALi.
470    * @note If render thread id getter doesn't supported, it will return 0 as default.
471    * @return The render thread id.
472    */
473   int32_t GetRenderThreadId() const;
474
475 public: //AdaptorInternalServices
476   /**
477    * @copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetPlatformAbstractionInterface()
478    */
479   Dali::Integration::PlatformAbstraction& GetPlatformAbstractionInterface() override;
480
481   /**
482    * @copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetDisplayConnectionInterface()
483    */
484   Dali::DisplayConnection& GetDisplayConnectionInterface() override;
485
486   /**
487    * @copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetGraphicsInterface()
488    */
489   GraphicsInterface& GetGraphicsInterface() override;
490
491   /**
492    * @copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetTriggerEventInterface()
493    */
494   TriggerEventInterface& GetProcessCoreEventsTrigger() override;
495
496   /**
497    * @copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetSocketFactoryInterface()
498    */
499   SocketFactoryInterface& GetSocketFactoryInterface() override;
500
501   /**
502    * @copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetRenderSurfaceInterface()
503    */
504   Dali::RenderSurfaceInterface* GetRenderSurfaceInterface() override;
505
506   /**
507    * @copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetPerformanceInterface()
508    */
509   PerformanceInterface* GetPerformanceInterface() override;
510
511   /**
512    * copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetKernelTraceInterface()
513    */
514   TraceInterface& GetKernelTraceInterface() override;
515
516   /**
517    * copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetSystemTraceInterface()
518    */
519   TraceInterface& GetSystemTraceInterface() override;
520
521   /**
522    * copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetWindowContainerInterface()
523    */
524   void GetWindowContainerInterface(WindowContainer& windows) override;
525
526   /**
527    * copydoc Dali::Internal::Adaptor::AdaptorInternalServices::GetTextureUploadManager()
528    */
529   Devel::TextureUploadManager& GetTextureUploadManager() override;
530
531   /**
532    * @brief Get the configuration manager
533    * @return The configuration manager, or null if it hasn't been created yet
534    */
535   const ConfigurationManager* GetConfigurationManager() const
536   {
537     return mConfigurationManager.get();
538   }
539
540 public: // Signals
541   /**
542    * @copydoc Dali::Adaptor::SignalResized
543    */
544   AdaptorSignalType& ResizedSignal()
545   {
546     return mResizedSignal;
547   }
548
549   /**
550    * @copydoc Dali::Adaptor::LanguageChangedSignal
551    */
552   AdaptorSignalType& LanguageChangedSignal()
553   {
554     return mLanguageChangedSignal;
555   }
556
557   /**
558    * @copydoc Dali::Adaptor::WindowCreatedSignal
559    */
560   WindowCreatedSignalType& WindowCreatedSignal()
561   {
562     return mWindowCreatedSignal;
563   }
564
565   /**
566    * @copydoc Dali::Adaptor::LocaleChangedSignal
567    */
568   LocaleChangedSignalType& LocaleChangedSignal()
569   {
570     return mLocaleChangedSignal;
571   }
572
573 public: // From Dali::Internal::Adaptor::CoreEventInterface
574   /**
575    * @copydoc Dali::Internal::Adaptor::CoreEventInterface:::FlushUpdateMessages()
576    */
577   void FlushUpdateMessages() override;
578
579   /**
580    * @copydoc Dali::Internal::Adaptor::CoreEventInterface:::ProcessCoreEvents()
581    */
582   void ProcessCoreEvents() override;
583
584 private: // From Dali::Internal::Adaptor::CoreEventInterface
585   /**
586    * @copydoc Dali::Internal::Adaptor::CoreEventInterface::QueueCoreEvent()
587    */
588   void QueueCoreEvent(const Dali::Integration::Event& event) override;
589
590 public: // From Dali::Integration::RenderController
591   /**
592    * @copydoc Dali::Integration::RenderController::RequestUpdate()
593    */
594   void RequestUpdate() override;
595
596   /**
597    * @copydoc Dali::Integration::RenderController::RequestProcessEventsOnIdle()
598    */
599   void RequestProcessEventsOnIdle() override;
600
601 public: // From Dali::Internal::Adaptor::WindowVisibilityObserver
602   /**
603    * Called when the window becomes fully or partially visible.
604    */
605   void OnWindowShown() override;
606
607   /**
608    * Called when the window is fully hidden.
609    */
610   void OnWindowHidden() override;
611
612 private: // From Dali::Internal::Adaptor::DamageObserver
613   /**
614    * @copydoc Dali::Internal::Adaptor::DamageObserver::OnDamaged()
615    */
616   void OnDamaged(const DamageArea& area) override;
617
618 private:
619   // Undefined
620   Adaptor(const Adaptor&) = delete;
621   Adaptor& operator=(Adaptor&) = delete;
622
623 private:
624   /**
625    * Assigns the render surface to the adaptor
626    *
627    */
628   void SetSurface(Dali::RenderSurfaceInterface* surface);
629
630   /**
631    * called after surface is created
632    */
633   void SurfaceInitialized();
634
635   /**
636    * Sends an notification message from main loop idle handler
637    */
638   bool ProcessCoreEventsFromIdle();
639
640   /**
641    * Gets path for data/resource storage.
642    * @param[out] path Path for data/resource storage
643    */
644   void GetDataStoragePath(std::string& path);
645
646   /**
647    * Sets up system information if needs
648    */
649   void SetupSystemInformation();
650
651   /**
652    * Remove system information if needs
653    */
654   void RemoveSystemInformation();
655
656   /**
657    * Adds a callback to be run when entering an idle state.
658    *
659    * A callback of the following type should be used:
660    * @code
661    *   bool MyFunction();
662    * @endcode
663    * This callback will be called repeatedly as long as it returns true. A return of 0 deletes this callback.
664    */
665   bool AddIdleEnterer(CallbackBase* callback);
666
667   /**
668    * Removes a previously added the idle enterer callback.
669    */
670   void RemoveIdleEnterer(CallbackBase* callback);
671
672   /**
673    * Trigger to log the memory pools from Core and Adaptor
674    */
675   bool MemoryPoolTimeout();
676
677 private:
678   /**
679    * Constructor
680    * @param[in]  window       window handle
681    * @param[in]  adaptor      The public adaptor
682    * @param[in]  surface      A render surface can be one of the following
683    *                          - Pixmap, adaptor will use existing Pixmap to draw on to
684    *                          - Window, adaptor will use existing Window to draw on to
685    * @param[in]  environmentOptions  A pointer to the environment options. If NULL then one is created.
686    * @param[in]  threadMode   The ThreadMode of the Adaptor
687    */
688   Adaptor(Dali::Integration::SceneHolder window, Dali::Adaptor& adaptor, Dali::RenderSurfaceInterface* surface, EnvironmentOptions* environmentOptions, ThreadMode threadMode);
689
690 private: // Types
691   enum State
692   {
693     READY,                     ///< Initial state before Adaptor::Start is called.
694     RUNNING,                   ///< Adaptor is running.
695     PAUSED,                    ///< Adaptor has been paused.
696     PAUSED_WHILE_HIDDEN,       ///< Adaptor is paused while window is hidden (& cannot be resumed until window is shown).
697     PAUSED_WHILE_INITIALIZING, ///< Adaptor is paused while application is initializing.
698     STOPPED,                   ///< Adaptor has been stopped.
699   };
700
701   // There is no weak handle for BaseHandle in DALi, but we can't ref count the window here,
702   // so we have to store the raw pointer.
703   using WindowContainer   = std::vector<Dali::Internal::Adaptor::SceneHolder*>;
704   using ObserverContainer = std::vector<LifeCycleObserver*>;
705
706 private:                                          // Data
707   AdaptorSignalType       mResizedSignal;         ///< Resized signal.
708   AdaptorSignalType       mLanguageChangedSignal; ///< Language changed signal.
709   WindowCreatedSignalType mWindowCreatedSignal;   ///< Window created signal.
710   LocaleChangedSignalType mLocaleChangedSignal;   ///< Locale changed signal.
711
712   Dali::Adaptor&           mAdaptor;          ///< Reference to public adaptor instance.
713   State                    mState;            ///< Current state of the adaptor
714   Dali::Integration::Core* mCore;             ///< Dali Core
715   ThreadController*        mThreadController; ///< Controls the threads
716
717   std::unique_ptr<GraphicsInterface> mGraphics;          ///< Graphics interface
718   Dali::DisplayConnection*           mDisplayConnection; ///< Display connection
719   WindowContainer                    mWindows;           ///< A container of all the Windows that are currently created
720
721   std::unique_ptr<ConfigurationManager> mConfigurationManager; ///< Configuration manager
722
723   TizenPlatform::TizenPlatformAbstraction* mPlatformAbstraction; ///< Platform abstraction
724
725   std::unique_ptr<CallbackManager> mCallbackManager;                       ///< Used to install callbacks
726   bool                             mNotificationOnIdleInstalled;           ///< whether the idle handler is installed to send an notification event
727   bool                             mRequiredIdleRepeat;                    ///< whether we need to repeat installed notification event in idle handler
728   TriggerEventInterface*           mNotificationTrigger;                   ///< Notification event trigger
729   FeedbackPluginProxy*             mDaliFeedbackPlugin;                    ///< Used to access feedback support
730   FeedbackController*              mFeedbackController;                    ///< Plays feedback effects for Dali-Toolkit UI Controls.
731   Dali::TtsPlayer                  mTtsPlayers[Dali::TtsPlayer::MODE_NUM]; ///< Provides TTS support
732   ObserverContainer                mObservers;                             ///< A list of adaptor observer pointers
733   EnvironmentOptions*              mEnvironmentOptions;                    ///< environment options
734   PerformanceInterface*            mPerformanceInterface;                  ///< Performance interface
735   KernelTrace                      mKernelTracer;                          ///< Kernel tracer
736   SystemTrace                      mSystemTracer;                          ///< System tracer
737   Devel::TextureUploadManager      mTextureUploadManager;                  ///< TextureUploadManager
738   ObjectProfiler*                  mObjectProfiler;                        ///< Tracks object lifetime for profiling
739   Dali::Timer                      mMemoryPoolTimer;                       ///< Logs memory pool capacity
740   SlotDelegate<Adaptor>            mMemoryPoolTimerSlotDelegate;
741   SocketFactory                    mSocketFactory;               ///< Socket factory
742   Mutex                            mMutex;                       ///< Mutex
743   ThreadMode                       mThreadMode;                  ///< The thread mode
744   const bool                       mEnvironmentOptionsOwned : 1; ///< Whether we own the EnvironmentOptions (and thus, need to delete it)
745   bool                             mUseRemoteSurface : 1;        ///< whether the remoteSurface is used or not
746   Dali::LayoutDirection::Type      mRootLayoutDirection;         ///< LayoutDirection of window
747
748   std::unique_ptr<Integration::AddOnManager> mAddOnManager; ///< Pointer to the addon manager
749
750 public:
751   inline static Adaptor& GetImplementation(Dali::Adaptor& adaptor)
752   {
753     return *adaptor.mImpl;
754   }
755 };
756
757 } // namespace Adaptor
758
759 } // namespace Internal
760
761 } // namespace Dali
762
763 #endif // DALI_INTERNAL_ADAPTOR_IMPL_H