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