[AT-SPI] Require ControlAccessible for Control
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / controls / control-impl.h
1 #ifndef DALI_TOOLKIT_CONTROL_IMPL_H
2 #define DALI_TOOLKIT_CONTROL_IMPL_H
3
4 /*
5  * Copyright (c) 2022 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/public-api/adaptor-framework/style-change.h>
23 #include <dali/public-api/animation/alpha-function.h>
24 #include <dali/public-api/animation/time-period.h>
25 #include <dali/public-api/events/long-press-gesture.h>
26 #include <dali/public-api/events/pan-gesture.h>
27 #include <dali/public-api/events/pinch-gesture.h>
28 #include <dali/public-api/events/tap-gesture.h>
29 #include <dali/public-api/object/property-index-ranges.h>
30 #include <dali/public-api/object/type-info.h>
31
32 // INTERNAL INCLUDES
33 #include <dali-toolkit/public-api/controls/control.h>
34
35 namespace Dali
36 {
37 namespace Toolkit
38 {
39 /**
40  * @addtogroup dali_toolkit_controls
41  * @{
42  */
43
44 class StyleManager;
45
46 namespace DevelControl
47 {
48 class ControlAccessible;
49
50 } // namespace DevelControl
51
52 namespace Internal
53 {
54
55 /**
56  * @brief This is the internal base class for all controls.
57  *
58  * It will provide some common functionality required by all controls.
59  * Implements ConnectionTrackerInterface so that signals (typically connected to member functions) will
60  * be disconnected automatically when the control is destroyed.
61  * @SINCE_1_0.0
62  */
63 class DALI_TOOLKIT_API Control : public CustomActorImpl, public ConnectionTrackerInterface
64 {
65 public:
66   class Extension; ///< Forward declare future extension interface
67
68   // Creation & Destruction
69   /**
70    * @brief Creates a new ControlImpl instance that does not require touch by default.
71    *
72    * If touch is required, then the user can connect to this class' touch signal.
73    * @SINCE_1_0.0
74    * @return A handle to the ControlImpl instance
75    */
76   static Toolkit::Control New();
77
78 protected:
79   /**
80    * @brief Virtual destructor.
81    * @SINCE_1_0.0
82    */
83   virtual ~Control();
84
85 public:
86   // Styling
87
88   /**
89    * @copydoc Dali::Toolkit::Control::SetStyleName
90    */
91   void SetStyleName(const std::string& styleName);
92
93   /**
94    * @copydoc Dali::Toolkit::Control::GetStyleName
95    */
96   const std::string& GetStyleName() const;
97
98   // Background
99
100   /**
101    * @copydoc Dali::Toolkit::Control::SetBackgroundColor
102    */
103   void SetBackgroundColor(const Vector4& color);
104
105   /**
106    * @brief Sets the background with a property map.
107    *
108    * @SINCE_1_0.0
109    * @param[in] map The background property map
110    */
111   void SetBackground(const Property::Map& map);
112
113   /**
114    * @copydoc Dali::Toolkit::Control::ClearBackground
115    */
116   void ClearBackground();
117
118   // Accessibility
119
120   /**
121    * @brief Gets the Accessible object that represents this control.
122    *
123    * This method creates the Accessible object if necessary, so a non-null return is expected.
124    *
125    * @return The Accessible object
126    */
127   Toolkit::DevelControl::ControlAccessible* GetAccessibleObject();
128
129   // Gesture Detection
130
131   /**
132    * @brief Allows deriving classes to enable any of the gesture detectors that are available.
133    *
134    * Gesture detection can be enabled one at a time or in bitwise format as shown:
135    * @code
136    * EnableGestureDetection(GestureType::Value(GestureType::PINCH | GestureType::TAP | GestureType::PAN));
137    * @endcode
138    * @SINCE_1_0.0
139    * @param[in] type The gesture type(s) to enable
140    */
141   void EnableGestureDetection(GestureType::Value type);
142
143   /**
144    * @brief Allows deriving classes to disable any of the gesture detectors.
145    *
146    * Like EnableGestureDetection, this can also be called using bitwise or.
147    * @SINCE_1_0.0
148    * @param[in] type The gesture type(s) to disable
149    * @see EnableGetureDetection
150    */
151   void DisableGestureDetection(GestureType::Value type);
152
153   /**
154    * @brief If deriving classes wish to fine tune pinch gesture
155    * detection, then they can access the gesture detector through this
156    * API and modify the detection.
157    *
158    * @SINCE_1_0.0
159    * @return The pinch gesture detector
160    * @pre Pinch detection should have been enabled via EnableGestureDetection().
161    * @see EnableGestureDetection
162    */
163   PinchGestureDetector GetPinchGestureDetector() const;
164
165   /**
166    * @brief If deriving classes wish to fine tune pan gesture
167    * detection, then they can access the gesture detector through this
168    * API and modify the detection.
169    *
170    * @SINCE_1_0.0
171    * @return The pan gesture detector
172    * @pre Pan detection should have been enabled via EnableGestureDetection().
173    * @see EnableGestureDetection
174    */
175   PanGestureDetector GetPanGestureDetector() const;
176
177   /**
178    * @brief If deriving classes wish to fine tune tap gesture
179    * detection, then they can access the gesture detector through this
180    * API and modify the detection.
181    *
182    * @SINCE_1_0.0
183    * @return The tap gesture detector
184    * @pre Tap detection should have been enabled via EnableGestureDetection().
185    * @see EnableGestureDetection
186    */
187   TapGestureDetector GetTapGestureDetector() const;
188
189   /**
190    * @brief If deriving classes wish to fine tune long press gesture
191    * detection, then they can access the gesture detector through this
192    * API and modify the detection.
193    *
194    * @SINCE_1_0.0
195    * @return The long press gesture detector
196    * @pre Long press detection should have been enabled via EnableGestureDetection().
197    * @see EnableGestureDetection
198    */
199   LongPressGestureDetector GetLongPressGestureDetector() const;
200
201   // Keyboard Navigation
202
203   /**
204    * @brief Sets whether this control supports two dimensional
205    * keyboard navigation (i.e. whether it knows how to handle the
206    * keyboard focus movement between its child actors).
207    *
208    * The control doesn't support it by default.
209    * @SINCE_1_0.0
210    * @param[in] isSupported Whether this control supports two dimensional keyboard navigation
211    */
212   void SetKeyboardNavigationSupport(bool isSupported);
213
214   /**
215    * @brief Gets whether this control supports two dimensional keyboard navigation.
216    *
217    * @SINCE_1_0.0
218    * @return true if this control supports two dimensional keyboard navigation
219    */
220   bool IsKeyboardNavigationSupported();
221
222   // Key Input
223
224   /**
225    * @copydoc Toolkit::Control::SetKeyInputFocus()
226    */
227   void SetKeyInputFocus();
228
229   /**
230    * @copydoc Toolkit::Control::HasKeyInputFocus()
231    */
232   bool HasKeyInputFocus();
233
234   /**
235    * @copydoc Toolkit::Control::ClearKeyInputFocus()
236    */
237   void ClearKeyInputFocus();
238
239   // Keyboard Focus
240
241   /**
242    * @brief Sets whether this control is a focus group for keyboard navigation.
243    *
244    * (i.e. the scope of keyboard focus movement
245    * can be limited to its child actors). The control is not a focus group by default.
246    * @SINCE_1_0.0
247    * @param[in] isFocusGroup Whether this control is set as a focus group for keyboard navigation
248    */
249   void SetAsKeyboardFocusGroup(bool isFocusGroup);
250
251   /**
252    * @brief Gets whether this control is a focus group for keyboard navigation.
253    *
254    * @SINCE_1_0.0
255    * @return true if this control is set as a focus group for keyboard navigation
256    */
257   bool IsKeyboardFocusGroup();
258
259   /// @cond internal
260   /**
261    * @brief Called by the AccessibilityManager to activate the Control.
262    * @SINCE_1_0.0
263    */
264   DALI_INTERNAL void AccessibilityActivate();
265
266   /**
267    * @brief Called by the KeyboardFocusManager.
268    * @SINCE_1_0.0
269    */
270   DALI_INTERNAL void KeyboardEnter();
271   /// @endcond
272
273
274   // Signals
275
276   /**
277    * @copydoc Dali::Toolkit::Control::KeyEventSignal()
278    */
279   Toolkit::Control::KeyEventSignalType& KeyEventSignal();
280
281   /**
282    * @copydoc Dali::Toolkit::Control::KeyInputFocusGainedSignal()
283    */
284   Toolkit::Control::KeyInputFocusSignalType& KeyInputFocusGainedSignal();
285
286   /**
287    * @copydoc Dali::Toolkit::Control::KeyInputFocusLostSignal()
288    */
289   Toolkit::Control::KeyInputFocusSignalType& KeyInputFocusLostSignal();
290
291   /// @cond internal
292   /**
293    * @brief Called by the KeyInputFocusManager to emit key event signals.
294    *
295    * @SINCE_1_0.0
296    * @param[in] event The key event
297    * @return True if the event was consumed
298    */
299   DALI_INTERNAL bool EmitKeyEventSignal(const KeyEvent& event);
300   /// @endcond
301
302 protected: // For derived classes to call
303   /**
304    * @brief Emits KeyInputFocusGained signal if true else emits KeyInputFocusLost signal.
305    *
306    * Should be called last by the control after it acts on the Input Focus change.
307    *
308    * @SINCE_1_0.0
309    * @param[in] focusGained True if gained, False if lost
310    */
311   void EmitKeyInputFocusSignal(bool focusGained);
312
313 protected: // From CustomActorImpl
314   /**
315    * @copydoc CustomActorImpl::OnSceneConnection()
316    * @note If overridden, then an up-call to Control::OnSceneConnection MUST be made at the end.
317    */
318   void OnSceneConnection(int depth) override;
319
320   /**
321    * @copydoc CustomActorImpl::OnSceneDisconnection()
322    * @note If overridden, then an up-call to Control::OnSceneDisconnection MUST be made at the end.
323    */
324   void OnSceneDisconnection() override;
325
326   /**
327    * @copydoc CustomActorImpl::OnChildAdd()
328    * @note If overridden, then an up-call to Control::OnChildAdd MUST be made at the end.
329    */
330   void OnChildAdd(Actor& child) override;
331
332   /**
333    * @copydoc CustomActorImpl::OnChildRemove()
334    * @note If overridden, then an up-call to Control::OnChildRemove MUST be made at the end.
335    */
336   void OnChildRemove(Actor& child) override;
337
338   /**
339    * @copydoc CustomActorImpl::OnPropertySet()
340    * @note If overridden, then an up-call to Control::OnChildRemove MUST be made at the end.
341    */
342   void OnPropertySet(Property::Index index, const Property::Value& propertyValue) override;
343
344   /**
345    * @copydoc CustomActorImpl::OnSizeSet()
346    * @note If overridden, then an up-call to Control::OnSizeSet MUST be made at the end.
347    */
348   void OnSizeSet(const Vector3& targetSize) override;
349
350   /**
351    * @copydoc CustomActorImpl::OnSizeAnimation()
352    * @note If overridden, then an up-call to Control::OnSizeAnimation MUST be made at the end.
353    */
354   void OnSizeAnimation(Animation& animation, const Vector3& targetSize) override;
355
356   /**
357    * @copydoc CustomActorImpl::OnRelayout()
358    */
359   void OnRelayout(const Vector2& size, RelayoutContainer& container) override;
360
361   /**
362    * @copydoc CustomActorImpl::OnSetResizePolicy()
363    */
364   void OnSetResizePolicy(ResizePolicy::Type policy, Dimension::Type dimension) override;
365
366   /**
367    * @copydoc CustomActorImpl::GetNaturalSize()
368    */
369   Vector3 GetNaturalSize() override;
370
371   /**
372    * @copydoc CustomActorImpl::CalculateChildSize()
373    */
374   float CalculateChildSize(const Dali::Actor& child, Dimension::Type dimension) override;
375
376   /**
377    * @copydoc CustomActorImpl::GetHeightForWidth()
378    */
379   float GetHeightForWidth(float width) override;
380
381   /**
382    * @copydoc CustomActorImpl::GetWidthForHeight()
383    */
384   float GetWidthForHeight(float height) override;
385
386   /**
387    * @copydoc CustomActorImpl::RelayoutDependentOnChildren()
388    */
389   bool RelayoutDependentOnChildren(Dimension::Type dimension = Dimension::ALL_DIMENSIONS) override;
390
391   /**
392    * @copydoc CustomActorImpl::OnCalculateRelayoutSize()
393    */
394   void OnCalculateRelayoutSize(Dimension::Type dimension) override;
395
396   /**
397    * @copydoc CustomActorImpl::OnLayoutNegotiated()
398    */
399   void OnLayoutNegotiated(float size, Dimension::Type dimension) override;
400
401 public: // Helpers for deriving classes
402
403   /**
404    * @brief Flags for the constructor.
405    * @SINCE_1_0.0
406    */
407   enum ControlBehaviour
408   {
409     CONTROL_BEHAVIOUR_DEFAULT            = 0, ///< Default behaviour: Size negotiation is enabled & listens to Style Change signal, but doesn't receive event callbacks. @SINCE_1_2_10
410     NOT_IN_USE_1                         = 1 << (CustomActorImpl::ACTOR_FLAG_COUNT + 0),
411     REQUIRES_KEYBOARD_NAVIGATION_SUPPORT = 1 << (CustomActorImpl::ACTOR_FLAG_COUNT + 1), ///< True if needs to support keyboard navigation @SINCE_1_0.0
412     DISABLE_STYLE_CHANGE_SIGNALS         = 1 << (CustomActorImpl::ACTOR_FLAG_COUNT + 2), ///< True if control should not monitor style change signals @SINCE_1_2_10
413
414     LAST_CONTROL_BEHAVIOUR_FLAG
415   };
416
417   static const int CONTROL_BEHAVIOUR_FLAG_COUNT = Log<LAST_CONTROL_BEHAVIOUR_FLAG - 1>::value + 1; ///< Total count of flags
418
419   /**
420    * @brief Creates a new ControlImpl instance that does not require touch by default.
421    *
422    * If touch is required, then the user can connect to this class' touch signal.
423    * @SINCE_2_1.8
424    * @param[in] additionalBehaviour Additional control behaviour.
425    * @return A handle to the ControlImpl instance
426    */
427   static Toolkit::Control New(ControlBehaviour additionalBehaviour);
428
429 protected:
430   // Construction
431
432   /**
433    * @brief Control constructor.
434    *
435    * @SINCE_1_0.0
436    * @param[in] behaviourFlags Behavioural flags from ControlBehaviour enum
437    */
438   Control(ControlBehaviour behaviourFlags);
439
440   /**
441    * @brief Second phase initialization.
442    * @SINCE_1_0.0
443    */
444   void Initialize();
445
446 public: // API for derived classes to override
447   // Lifecycle
448
449   /**
450    * @brief This method is called after the Control has been initialized.
451    *
452    * Derived classes should do any second phase initialization by overriding this method.
453    * @SINCE_1_0.0
454    */
455   virtual void OnInitialize();
456
457   // Styling
458
459   /**
460    * @brief This method should be overridden by deriving classes requiring notifications when the style changes.
461    *
462    * @SINCE_1_0.0
463    * @param[in] styleManager The StyleManager object
464    * @param[in] change Information denoting what has changed
465    */
466   virtual void OnStyleChange(Toolkit::StyleManager styleManager, StyleChange::Type change);
467
468   // Accessibility
469
470   /**
471    * @brief This method is called when the control is accessibility activated.
472    *
473    * Derived classes should override this to perform custom accessibility activation.
474    * @SINCE_1_0.0
475    * @return true if this control can perform accessibility activation
476    */
477   virtual bool OnAccessibilityActivated();
478
479   /**
480    * @brief This method should be overridden by deriving classes when they wish to respond the accessibility
481    * pan gesture.
482    *
483    * @SINCE_1_0.0
484    * @param[in] gesture The pan gesture
485    * @return true if the pan gesture has been consumed by this control
486    */
487   virtual bool OnAccessibilityPan(PanGesture gesture);
488
489   /**
490    * @brief This method should be overridden by deriving classes when they wish to respond
491    * the accessibility up and down action (i.e. value change of slider control).
492    *
493    * @SINCE_1_0.0
494    * @param[in] isIncrease Whether the value should be increased or decreased
495    * @return true if the value changed action has been consumed by this control
496    */
497   virtual bool OnAccessibilityValueChange(bool isIncrease);
498
499   /**
500    * @brief This method should be overridden by deriving classes when they wish to respond
501    * the accessibility zoom action.
502    *
503    * @SINCE_1_0.0
504    * @return true if the zoom action has been consumed by this control
505    */
506   virtual bool OnAccessibilityZoom();
507
508   // Keyboard focus
509
510   /**
511    * @brief Called when the control gains key input focus.
512    *
513    * Should be overridden by derived classes if they need to customize what happens when focus is gained.
514    * @SINCE_1_0.0
515    */
516   virtual void OnKeyInputFocusGained();
517
518   /**
519    * @brief Called when the control loses key input focus.
520    *
521    * Should be overridden by derived classes if they need to customize what happens when focus is lost.
522    * @SINCE_1_0.0
523    */
524   virtual void OnKeyInputFocusLost();
525
526   /**
527    * @brief Gets the next keyboard focusable actor in this control towards the given direction.
528    *
529    * A control needs to override this function in order to support two dimensional keyboard navigation.
530    * @SINCE_1_0.0
531    * @param[in] currentFocusedActor The current focused actor
532    * @param[in] direction The direction to move the focus towards
533    * @param[in] loopEnabled Whether the focus movement should be looped within the control
534    * @return The next keyboard focusable actor in this control or an empty handle if no actor can be focused
535    */
536   virtual Actor GetNextKeyboardFocusableActor(Actor currentFocusedActor, Toolkit::Control::KeyboardFocus::Direction direction, bool loopEnabled);
537
538   /**
539    * @brief Informs this control that its chosen focusable actor will be focused.
540    *
541    * This allows the application to perform any actions if wishes
542    * before the focus is actually moved to the chosen actor.
543    *
544    * @SINCE_1_0.0
545    * @param[in] commitedFocusableActor The commited focusable actor
546    */
547   virtual void OnKeyboardFocusChangeCommitted(Actor commitedFocusableActor);
548
549   /**
550    * @brief This method is called when the control has enter pressed on it.
551    *
552    * Derived classes should override this to perform custom actions.
553    * @SINCE_1_0.0
554    * @return true if this control supported this action
555    */
556   virtual bool OnKeyboardEnter();
557
558   /**
559    * @brief Called after a key-event is received by the actor that has had its focus set.
560    *
561    * @SINCE_1_0.0
562    * @param[in] event The Key Event
563    * @return True if the event should be consumed
564    */
565   virtual bool OnKeyEvent(const KeyEvent& event);
566
567   // Gestures
568
569   /**
570    * @brief Called whenever a pinch gesture is detected on this control.
571    *
572    * This can be overridden by deriving classes when pinch detection
573    * is enabled.  The default behaviour is to scale the control by the
574    * pinch scale.
575    *
576    * @SINCE_1_0.0
577    * @param[in] pinch The pinch gesture
578    * @note If overridden, then the default behavior will not occur.
579    * @note Pinch detection should be enabled via EnableGestureDetection().
580    * @see EnableGestureDetection
581    */
582   virtual void OnPinch(const PinchGesture& pinch);
583
584   /**
585    * @brief Called whenever a pan gesture is detected on this control.
586    *
587    * This should be overridden by deriving classes when pan detection
588    * is enabled.
589    *
590    * @SINCE_1_0.0
591    * @param[in] pan The pan gesture
592    * @note There is no default behavior with panning.
593    * @note Pan detection should be enabled via EnableGestureDetection().
594    * @see EnableGestureDetection
595    */
596   virtual void OnPan(const PanGesture& pan);
597
598   /**
599    * @brief Called whenever a tap gesture is detected on this control.
600    *
601    * This should be overridden by deriving classes when tap detection
602    * is enabled.
603    *
604    * @SINCE_1_0.0
605    * @param[in] tap The tap gesture
606    * @note There is no default behavior with a tap.
607    * @note Tap detection should be enabled via EnableGestureDetection().
608    * @see EnableGestureDetection
609    */
610   virtual void OnTap(const TapGesture& tap);
611
612   /**
613    * @brief Called whenever a long press gesture is detected on this control.
614    *
615    * This should be overridden by deriving classes when long press
616    * detection is enabled.
617    *
618    * @SINCE_1_0.0
619    * @param[in] longPress The long press gesture
620    * @note There is no default behaviour associated with a long press.
621    * @note Long press detection should be enabled via EnableGestureDetection().
622    * @see EnableGestureDetection
623    */
624   virtual void OnLongPress(const LongPressGesture& longPress);
625
626   // From ConnectionTrackerInterface
627
628   /**
629    * @copydoc ConnectionTrackerInterface::SignalConnected
630    */
631   void SignalConnected(SlotObserver* slotObserver, CallbackBase* callback) override;
632
633   /**
634    * @copydoc ConnectionTrackerInterface::SignalDisconnected
635    */
636   void SignalDisconnected(SlotObserver* slotObserver, CallbackBase* callback) override;
637
638   /**
639    * @brief Retrieves the extension for this control.
640    *
641    * @SINCE_1_0.0
642    * @return The extension if available, NULL otherwise
643    */
644   virtual Extension* GetControlExtension()
645   {
646     return NULL;
647   }
648
649   // Transition APIs
650
651   /**
652    * @brief Make visual transition from source control to destination control about specific Visual.
653    * If both of source and destination control have same visual index, than generates information for the transition of this Control.
654    *
655    * @param[out] sourcePropertyMap Source property map to be applied on this Control.
656    * @param[out] destinationPropertyMap Destination property map to be applied on this Control.
657    * @param[in] source Source control of the animation.
658    * @param[in] destination Destination control of the animation.
659    * @param[in] visualIndex Property::Index to make animation.
660    */
661   void MakeVisualTransition(Dali::Property::Map& sourcePropertyMap, Dali::Property::Map& destinationPropertyMap,
662                             Dali::Toolkit::Control source, Dali::Toolkit::Control destination, Dali::Property::Index visualIndex);
663
664   /**
665    * @brief Retrieves source and destination visual properties for the Transition of this Control.
666    * The properties of this Control will be transitioned from the propeties of source Control to that of destination control.
667    * If a property value is different between source and destination Control,
668    * the property information of each Control will be included in sourceProperties and destinationProperties.
669    *
670    * @param[out] sourceProperties Source property list to be applied on this Control.
671    * @param[out] destinationProperties Destination property list to be applied on this Control.
672    * @param[in] source Source control of the animation.
673    * @param[in] destination Destination control of the animation.
674    *
675    * @note This method do not handle Actor properties.
676    * And the size and order of the sourceProperties and destinationProperties must be synchronized.
677    */
678   virtual void OnCreateTransitions(std::vector<std::pair<Dali::Property::Index, Dali::Property::Map>>& sourceProperties,
679                                    std::vector<std::pair<Dali::Property::Index, Dali::Property::Map>>& destinationProperties,
680                                    Dali::Toolkit::Control                                              source,
681                                    Dali::Toolkit::Control                                              destination)
682   {
683   }
684
685   /**
686    * @brief Update visual properties.
687    * @param[in] properties Property list to be used to update visual properties of this Control.
688    */
689   virtual void OnUpdateVisualProperties(const std::vector<std::pair<Dali::Property::Index, Dali::Property::Map>>& properties)
690   {
691   }
692
693 private:
694   /// @cond internal
695
696   // Not copyable or movable
697   DALI_INTERNAL Control(const Control&) = delete;            ///< Deleted copy constructor.
698   DALI_INTERNAL Control(Control&&)      = delete;            ///< Deleted move constructor.
699   DALI_INTERNAL Control& operator=(const Control&) = delete; ///< Deleted copy assignment operator.
700   DALI_INTERNAL Control& operator=(Control&&) = delete;      ///< Deleted move assignment operator.
701
702 public:
703   class DALI_INTERNAL Impl; // Class declaration is public so we can internally add devel API's to the Controls Impl
704
705 private:
706   Impl* mImpl;
707   /// @endcond
708 };
709
710 /**
711  * @brief Gets implementation from the handle.
712  *
713  * @SINCE_1_0.0
714  * @param handle
715  * @return Implementation
716  * @pre handle is initialized and points to a control
717  */
718 DALI_TOOLKIT_API Internal::Control& GetImplementation(Dali::Toolkit::Control& handle);
719
720 /**
721  * @brief Gets implementation from the handle.
722  *
723  * @SINCE_1_0.0
724  * @param handle
725  * @return Implementation
726  * @pre Handle is initialized and points to a control.
727  */
728 DALI_TOOLKIT_API const Internal::Control& GetImplementation(const Dali::Toolkit::Control& handle);
729
730 } // namespace Internal
731
732 /**
733  * @}
734  */
735 } // namespace Toolkit
736
737 } // namespace Dali
738
739 #endif // DALI_TOOLKIT_CONTROL_IMPL_H