-#ifndef __DALI_TOOLKIT_POPUP_H__
-#define __DALI_TOOLKIT_POPUP_H__
+#ifndef DALI_TOOLKIT_POPUP_H
+#define DALI_TOOLKIT_POPUP_H
/*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2022 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
namespace Dali
{
-
namespace Toolkit
{
-
namespace Internal DALI_INTERNAL
{
class Popup;
* Signals
* | %Signal Name | Method |
* |-------------------|------------------------------|
- * | touched-outside | @ref OutsideTouchedSignal() |
+ * | touchedOutside | @ref OutsideTouchedSignal() |
* | showing | @ref ShowingSignal() |
* | shown | @ref ShownSignal() |
* | hiding | @ref HidingSignal() |
* | hidden | @ref HiddenSignal() |
*/
-class DALI_IMPORT_API Popup : public Control
+class DALI_TOOLKIT_API Popup : public Control
{
-
public:
-
/**
* @brief The start and end property ranges for this control.
*/
enum PropertyRange
{
PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1,
- PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices
+ PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices
};
/**
TITLE = PROPERTY_START_INDEX, ///< name "title", type Property::Map
CONTENT, ///< name "content", type Property::Map
FOOTER, ///< name "footer", type Property::Map
- DISPLAY_STATE, ///< name "display-state", type std::string
- TOUCH_TRANSPARENT, ///< name "touch-transparent", type bool
- TAIL_VISIBILITY, ///< name "tail-visibility", type bool
- TAIL_POSITION, ///< name "tail-position", type Vector3
- CONTEXTUAL_MODE, ///< name "contextual-mode", type std::string
- ANIMATION_DURATION, ///< name "animation-duration", type float
- ANIMATION_MODE, ///< name "animation-mode", type std::string
- ENTRY_ANIMATION, ///< name "entry-animation", type Property::Map
- EXIT_ANIMATION, ///< name "exit-animation", type Property::Map
- AUTO_HIDE_DELAY, ///< name "auto-hide-delay", type int
- BACKING_ENABLED, ///< name "backing-enabled", type bool
- BACKING_COLOR, ///< name "backing-color", type Vector4
- POPUP_BACKGROUND_IMAGE, ///< name "popup-background-image", type std::string
- TAIL_UP_IMAGE, ///< name "tail-up-image", type std::string
- TAIL_DOWN_IMAGE, ///< name "tail-down-image", type std::string
- TAIL_LEFT_IMAGE, ///< name "tail-left-image", type std::string
- TAIL_RIGHT_IMAGE, ///< name "tail-right-image", type std::string
+ DISPLAY_STATE, ///< name "displayState", type std::string
+ TOUCH_TRANSPARENT, ///< name "touchTransparent", type bool
+ TAIL_VISIBILITY, ///< name "tailVisibility", type bool
+ TAIL_POSITION, ///< name "tailPosition", type Vector3
+ CONTEXTUAL_MODE, ///< name "contextualMode", type std::string
+ ANIMATION_DURATION, ///< name "animationDuration", type float
+ ANIMATION_MODE, ///< name "animationMode", type std::string
+ ENTRY_ANIMATION, ///< name "entryAnimation", type Property::Map
+ EXIT_ANIMATION, ///< name "exitAnimation", type Property::Map
+ AUTO_HIDE_DELAY, ///< name "autoHideDelay", type int
+ BACKING_ENABLED, ///< name "backingEnabled", type bool
+ BACKING_COLOR, ///< name "backingColor", type Vector4
+ POPUP_BACKGROUND_IMAGE, ///< name "popupBackgroundImage", type std::string
+ POPUP_BACKGROUND_BORDER, ///< name "popupBackgroundBorder", type Rect< int >, Values are in the order: left, right, bottom, top
+ TAIL_UP_IMAGE, ///< name "tailUpImage", type std::string
+ TAIL_DOWN_IMAGE, ///< name "tailDownImage", type std::string
+ TAIL_LEFT_IMAGE, ///< name "tailLeftImage", type std::string
+ TAIL_RIGHT_IMAGE, ///< name "tailRightImage", type std::string
};
};
*/
enum DisplayState
{
- SHOWING, ///< The popup is transitioning in
- SHOWN, ///< The popup is fully shown
- HIDING, ///< The popup is transitioning out
- HIDDEN ///< The popup is fully hidden
+ SHOWING, ///< The popup is transitioning in
+ SHOWN, ///< The popup is fully shown
+ HIDING, ///< The popup is transitioning out
+ HIDDEN ///< The popup is fully hidden
};
/**
*/
enum AnimationMode
{
- NONE, ///< No animation.
- ZOOM, ///< Popup zooms in and out animating the scale property.
- FADE, ///< Popup fades in and out.
- CUSTOM ///< Use the EntryAnimation and ExitAnimation animation properties.
+ NONE, ///< No animation.
+ ZOOM, ///< Popup zooms in and out animating the scale property.
+ FADE, ///< Popup fades in and out.
+ CUSTOM ///< Use the EntryAnimation and ExitAnimation animation properties.
};
/**
};
public:
-
/**
* @brief Creates an empty Popup handle.
*/
* Creates another handle that points to the same real object
* @param[in] handle Handle to the copied object
*/
- Popup( const Popup& handle );
+ Popup(const Popup& handle);
/**
* @brief Assignment operator.
* @param[in] handle Handle to the object
* @return A reference to this
*/
- Popup& operator=( const Popup& handle );
+ Popup& operator=(const Popup& handle);
+
+ /**
+ * @brief Move constructor.
+ *
+ * Creates another handle that points to the same real object
+ * @param[in] handle Handle to the moved object
+ */
+ Popup(Popup&& handle);
+
+ /**
+ * @brief Move assignment operator.
+ *
+ * Changes this handle to point to another real object
+ * @param[in] handle Handle to the object
+ * @return A reference to this
+ */
+ Popup& operator=(Popup&& handle);
/**
* @brief Downcast an Object handle to Popup.
* @param[in] handle Handle to an object
* @return handle to a Popup or an uninitialized handle
*/
- static Popup DownCast( BaseHandle handle );
+ static Popup DownCast(BaseHandle handle);
public:
-
/**
* @brief Sets a title for this Popup.
*
* @param[in] titleActor Any actor can be specified when using this method.
*/
- void SetTitle( Actor titleActor );
+ void SetTitle(Actor titleActor);
/**
* @brief Gets the title actor for this Popup.
*
* @param[in] content The actor to use.
*/
- void SetContent( Actor content );
+ void SetContent(Actor content);
/**
* @brief Gets the actor currently used for the content.
/**
* @brief Sets the actor to use for a footer in this Popup.
*
- * @param[in] control The footer actor to be added to this Popup
+ * @param[in] footer The footer actor to be added to this Popup
*/
- void SetFooter( Actor footer );
+ void SetFooter(Actor footer);
/**
* @brief Gets the footer actor.
*
* @param[in] displayState The desired display state to change to.
*/
- void SetDisplayState( Toolkit::Popup::DisplayState displayState );
+ void SetDisplayState(Toolkit::Popup::DisplayState displayState);
/**
* @brief Gets the current state of the popup.
Toolkit::Popup::DisplayState GetDisplayState() const;
public:
-
- typedef Signal< void () > TouchedOutsideSignalType; ///< Touched outside signal type.
- typedef Signal< void () > DisplayStateChangeSignalType; ///< Used for signals emitted when the displayed state changes.
+ typedef Signal<void()> TouchedOutsideSignalType; ///< Touched outside signal type.
+ typedef Signal<void()> DisplayStateChangeSignalType; ///< Used for signals emitted when the displayed state changes.
/**
* @brief Signal emitted when user has touched outside of the Dialog.
DisplayStateChangeSignalType& HiddenSignal();
public: // Not intended for application developers
-
/**
* @brief Creates a handle using the Toolkit::Internal implementation.
*
* @param[in] implementation The Control implementation.
*/
- DALI_INTERNAL Popup( Internal::Popup& implementation );
+ DALI_INTERNAL Popup(Internal::Popup& implementation);
/**
* @brief Allows the creation of this Control from an Internal::CustomActor pointer.
*
* @param[in] internal A pointer to the internal CustomActor.
*/
- explicit DALI_INTERNAL Popup( Dali::Internal::CustomActor* internal );
+ explicit DALI_INTERNAL Popup(Dali::Internal::CustomActor* internal);
};
} // namespace Toolkit
} // namespace Dali
-#endif // __DALI_TOOLKIT_POPUP_H__
+#endif // DALI_TOOLKIT_POPUP_H