From 81493443fac5b04da1564d38bd00ed716d891a00 Mon Sep 17 00:00:00 2001 From: "jk7744.park" Date: Wed, 24 Feb 2016 18:36:40 +0900 Subject: [PATCH] Tizen 2.4.0 rev3 SDK Public Release --- automated-tests/src/dali-toolkit/CMakeLists.txt | 1 + .../test-platform-abstraction.cpp | 8 + .../test-platform-abstraction.h | 5 + .../toolkit-imf-manager.cpp | 36 +- .../dali-toolkit-test-utils/toolkit-imf-manager.h | 142 ++--- .../src/dali-toolkit/utc-Dali-ItemView.cpp | 4 +- .../src/dali-toolkit/utc-Dali-Model3dView.cpp | 212 +++++++ .../src/dali-toolkit/utc-Dali-ScrollView.cpp | 62 -- .../src/dali-toolkit/utc-Dali-TextField.cpp | 10 +- build/tizen/configure.ac | 1 - build/tizen/dali-toolkit/Makefile.am | 17 +- dali-toolkit/dali-toolkit.h | 1 + .../controls/text-controls/text-selection-popup.h | 1 - .../text-controls/text-selection-toolbar.h | 5 +- .../images-common => images}/00_popup_bg.9.png | Bin .../images-common => images}/00_popup_bg.png | Bin .../00_popup_bottom_bg.png | Bin .../00_popup_bubble_bg.png | Bin .../00_popup_bubble_tail_bottom.png | Bin .../00_popup_button_bg.png | Bin .../00_popup_button_pressed.png | Bin .../images-common => images}/B16-8_TTS_focus.png | Bin .../images-common => images}/button-disabled.9.png | Bin .../button-down-disabled.9.png | Bin .../images-common => images}/button-down.9.png | Bin .../images-common => images}/button-up.9.png | Bin .../checkbox-selected-diabled.png | Bin .../images-common => images}/checkbox-selected.png | Bin .../checkbox-unselected-disabled.png | Bin .../checkbox-unselected.png | Bin .../copy_paste_icon_clipboard.png | Bin .../copy_paste_icon_copy.png | Bin .../copy_paste_icon_cut.png | Bin .../copy_paste_icon_paste.png | Bin .../copy_paste_icon_select.png | Bin .../copy_paste_icon_select_all.png | Bin .../core_contextual_popup_bg_stroke_color.9.png | Bin 459 -> 0 bytes .../cursor_handler_center.png} | Bin .../{styles/images-common => images}/file.list | 0 .../insertpoint-icon-pressed.png | Bin .../images-common => images}/insertpoint-icon.png | Bin .../images-common => images}/keyboard_focus.png | Bin .../magnifier-image-frame.png | Bin .../{styles/images-common => images}/magnifier.png | Bin .../{styles/images-common => images}/popup_bg.png | Bin .../images-common => images}/popup_bubble_bg.#.png | Bin .../popup_bubble_bg_ef.#.png | Bin .../popup_bubble_bg_line.#.png | Bin .../popup_bubble_tail_bottom.png | Bin .../popup_bubble_tail_bottom_ef.png | Bin .../popup_bubble_tail_bottom_line.png | Bin .../popup_bubble_tail_top.png | Bin .../popup_bubble_tail_top_ef.png | Bin .../popup_bubble_tail_top_line.png | Bin .../images-common => images}/popup_scroll.png | Bin .../images-common => images}/popup_tail_down.png | Bin .../images-common => images}/popup_tail_left.png | Bin .../images-common => images}/popup_tail_right.png | Bin .../images-common => images}/popup_tail_up.png | Bin .../radio-button-selected-disabled.png | Bin .../radio-button-selected.png | Bin .../radio-button-unselected-disabled.png | Bin .../radio-button-unselected.png | Bin .../selection-popup-bg.9.png | Bin dali-toolkit/images/selection_handle_left.png | Bin 0 -> 558 bytes dali-toolkit/images/selection_handle_right.png | Bin 0 -> 553 bytes .../selection_marker_left.png | Bin .../selection_marker_right.png | Bin .../slider-popup-arrow.png | Bin .../images-common => images}/slider-popup.9.png | Bin .../images-common => images}/slider-popup.png | Bin .../slider-skin-handle.png | Bin .../slider-skin-progress.9.png | Bin .../slider-skin-progress.png | Bin .../images-common => images}/slider-skin.9.png | Bin .../images-common => images}/slider-skin.png | Bin .../text-input-selection-handle-left-press.png | Bin .../text-input-selection-handle-left.png | Bin .../text-input-selection-handle-right-press.png | Bin .../text-input-selection-handle-right.png | Bin dali-toolkit/internal/builder/builder-impl.cpp | 1 - .../controls/image-view/image-view-impl.cpp | 1 - .../controls/model3d-view/model3d-view-impl.cpp | 675 +++++++++++++++++++++ .../controls/model3d-view/model3d-view-impl.h | 195 ++++++ .../internal/controls/model3d-view/obj-loader.cpp | 587 ++++++++++++++++++ .../internal/controls/model3d-view/obj-loader.h | 157 +++++ .../controls/scroll-bar/scroll-bar-impl.cpp | 25 +- .../internal/controls/scroll-bar/scroll-bar-impl.h | 5 +- .../controls/scrollable/bouncing-effect-actor.cpp | 9 +- .../scrollable/item-view/item-view-impl.cpp | 163 ++--- .../controls/scrollable/item-view/item-view-impl.h | 58 +- .../scroll-overshoot-indicator-impl.cpp | 18 +- .../scroll-view/scroll-overshoot-indicator-impl.h | 5 +- .../scrollable/scroll-view/scroll-view-impl.cpp | 253 +++----- .../scrollable/scroll-view/scroll-view-impl.h | 7 +- .../controls/scrollable/scrollable-impl.cpp | 20 +- .../internal/controls/scrollable/scrollable-impl.h | 6 - .../controls/table-view/table-view-impl.cpp | 2 +- .../controls/text-controls/text-field-impl.cpp | 6 +- .../controls/text-controls/text-label-impl.cpp | 5 +- .../text-controls/text-selection-popup-impl.cpp | 277 +-------- .../text-controls/text-selection-popup-impl.h | 29 +- .../text-controls/text-selection-toolbar-impl.cpp | 102 +--- .../text-controls/text-selection-toolbar-impl.h | 28 +- dali-toolkit/internal/file.list | 2 + .../focus-manager/keyboard-focus-manager-impl.cpp | 2 +- .../internal/text/decorator/text-decorator.cpp | 478 ++++----------- .../internal/text/decorator/text-decorator.h | 17 - .../internal/text/layouts/layout-engine.cpp | 6 +- .../text/rendering/atlas/text-atlas-renderer.cpp | 68 +-- .../internal/text/text-controller-impl.cpp | 570 ++++++++--------- dali-toolkit/internal/text/text-controller-impl.h | 43 +- dali-toolkit/internal/text/text-controller.cpp | 133 ++-- .../accessibility-manager/accessibility-manager.h | 165 ++--- .../public-api/controls/alignment/alignment.h | 54 +- dali-toolkit/public-api/controls/buttons/button.h | 120 ++-- .../public-api/controls/buttons/check-box-button.h | 36 +- .../public-api/controls/buttons/push-button.h | 59 +- .../public-api/controls/buttons/radio-button.h | 16 +- .../controls/control-depth-index-ranges.h | 2 +- dali-toolkit/public-api/controls/control-impl.cpp | 8 +- dali-toolkit/public-api/controls/control-impl.h | 64 +- dali-toolkit/public-api/controls/control.h | 88 ++- .../controls/default-controls/solid-color-actor.h | 7 +- .../gaussian-blur-view/gaussian-blur-view.h | 94 +-- .../public-api/controls/image-view/image-view.h | 26 +- .../controls/model3d-view/model3d-view.cpp | 87 +++ .../controls/model3d-view/model3d-view.h | 186 ++++++ .../public-api/controls/scroll-bar/scroll-bar.h | 100 ++- .../scrollable/item-view/default-item-layout.h | 15 +- .../controls/scrollable/item-view/item-factory.h | 11 +- .../controls/scrollable/item-view/item-layout.h | 48 +- .../scrollable/item-view/item-view-declarations.h | 18 +- .../controls/scrollable/item-view/item-view.h | 108 +--- .../scroll-view/scroll-view-constraints.h | 8 +- .../scrollable/scroll-view/scroll-view-effect.h | 5 +- .../scroll-view/scroll-view-page-path-effect.h | 24 +- .../controls/scrollable/scroll-view/scroll-view.h | 245 +++----- .../public-api/controls/scrollable/scrollable.h | 68 +-- .../public-api/controls/table-view/table-view.h | 201 +++--- .../public-api/controls/text-controls/text-field.h | 106 ++-- .../public-api/controls/text-controls/text-label.h | 46 +- dali-toolkit/public-api/enums.h | 15 +- dali-toolkit/public-api/file.list | 4 + .../focus-manager/keyboard-focus-manager.h | 65 +- dali-toolkit/public-api/text/rendering-backend.h | 19 +- .../styles/480x800/dali-toolkit-default-theme.json | 46 +- .../480x800/images/cursor_handler_drop_center.png | Bin 3231 -> 0 bytes .../480x800/images/selection_handle_drop_left.png | Bin 3230 -> 0 bytes .../480x800/images/selection_handle_drop_right.png | Bin 3236 -> 0 bytes .../720x1280/dali-toolkit-default-theme.json | 44 +- .../720x1280/images/cursor_handler_drop_center.png | Bin 3615 -> 0 bytes .../720x1280/images/selection_handle_drop_left.png | Bin 3455 -> 0 bytes .../images/selection_handle_drop_right.png | Bin 3459 -> 0 bytes dali-toolkit/styles/file.list | 3 - .../core_contextual_popup_bg_stroke_color.9.png | Bin 459 -> 0 bytes .../styles/images-common/popup_scroll_white.9.png | Bin 227 -> 0 bytes .../images-common/selection_handle_ball_left.png | Bin 546 -> 0 bytes .../images-common/selection_handle_ball_right.png | Bin 545 -> 0 bytes doc/dali-toolkit_doc.h | 141 +---- doc/images/dali-modules.png | Bin 27466 -> 0 bytes docs/content/main.md | 1 - docs/content/programming-guide/styling.h | 62 -- packaging/dali-toolkit.spec | 11 +- 164 files changed, 3597 insertions(+), 3287 deletions(-) create mode 100644 automated-tests/src/dali-toolkit/utc-Dali-Model3dView.cpp rename dali-toolkit/{styles/images-common => images}/00_popup_bg.9.png (100%) rename dali-toolkit/{styles/images-common => images}/00_popup_bg.png (100%) rename dali-toolkit/{styles/images-common => images}/00_popup_bottom_bg.png (100%) rename dali-toolkit/{styles/images-common => images}/00_popup_bubble_bg.png (100%) rename dali-toolkit/{styles/images-common => images}/00_popup_bubble_tail_bottom.png (100%) rename dali-toolkit/{styles/images-common => images}/00_popup_button_bg.png (100%) rename dali-toolkit/{styles/images-common => images}/00_popup_button_pressed.png (100%) rename dali-toolkit/{styles/images-common => images}/B16-8_TTS_focus.png (100%) rename dali-toolkit/{styles/images-common => images}/button-disabled.9.png (100%) rename dali-toolkit/{styles/images-common => images}/button-down-disabled.9.png (100%) rename dali-toolkit/{styles/images-common => images}/button-down.9.png (100%) rename dali-toolkit/{styles/images-common => images}/button-up.9.png (100%) rename dali-toolkit/{styles/images-common => images}/checkbox-selected-diabled.png (100%) rename dali-toolkit/{styles/images-common => images}/checkbox-selected.png (100%) rename dali-toolkit/{styles/images-common => images}/checkbox-unselected-disabled.png (100%) rename dali-toolkit/{styles/images-common => images}/checkbox-unselected.png (100%) rename dali-toolkit/{styles/images-common => images}/copy_paste_icon_clipboard.png (100%) rename dali-toolkit/{styles/images-common => images}/copy_paste_icon_copy.png (100%) rename dali-toolkit/{styles/images-common => images}/copy_paste_icon_cut.png (100%) rename dali-toolkit/{styles/images-common => images}/copy_paste_icon_paste.png (100%) rename dali-toolkit/{styles/images-common => images}/copy_paste_icon_select.png (100%) rename dali-toolkit/{styles/images-common => images}/copy_paste_icon_select_all.png (100%) delete mode 100644 dali-toolkit/images/core_contextual_popup_bg_stroke_color.9.png rename dali-toolkit/{styles/images-common/cursor_handler_ball_center.png => images/cursor_handler_center.png} (100%) rename dali-toolkit/{styles/images-common => images}/file.list (100%) rename dali-toolkit/{styles/images-common => images}/insertpoint-icon-pressed.png (100%) rename dali-toolkit/{styles/images-common => images}/insertpoint-icon.png (100%) rename dali-toolkit/{styles/images-common => images}/keyboard_focus.png (100%) rename dali-toolkit/{styles/images-common => images}/magnifier-image-frame.png (100%) rename dali-toolkit/{styles/images-common => images}/magnifier.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bg.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_bg.#.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_bg_ef.#.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_bg_line.#.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_tail_bottom.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_tail_bottom_ef.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_tail_bottom_line.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_tail_top.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_tail_top_ef.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_bubble_tail_top_line.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_scroll.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_tail_down.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_tail_left.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_tail_right.png (100%) rename dali-toolkit/{styles/images-common => images}/popup_tail_up.png (100%) rename dali-toolkit/{styles/images-common => images}/radio-button-selected-disabled.png (100%) rename dali-toolkit/{styles/images-common => images}/radio-button-selected.png (100%) rename dali-toolkit/{styles/images-common => images}/radio-button-unselected-disabled.png (100%) rename dali-toolkit/{styles/images-common => images}/radio-button-unselected.png (100%) rename dali-toolkit/{styles/images-common => images}/selection-popup-bg.9.png (100%) create mode 100755 dali-toolkit/images/selection_handle_left.png create mode 100755 dali-toolkit/images/selection_handle_right.png rename dali-toolkit/{styles/images-common => images}/selection_marker_left.png (100%) rename dali-toolkit/{styles/images-common => images}/selection_marker_right.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-popup-arrow.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-popup.9.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-popup.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-skin-handle.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-skin-progress.9.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-skin-progress.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-skin.9.png (100%) rename dali-toolkit/{styles/images-common => images}/slider-skin.png (100%) rename dali-toolkit/{styles/images-common => images}/text-input-selection-handle-left-press.png (100%) rename dali-toolkit/{styles/images-common => images}/text-input-selection-handle-left.png (100%) rename dali-toolkit/{styles/images-common => images}/text-input-selection-handle-right-press.png (100%) rename dali-toolkit/{styles/images-common => images}/text-input-selection-handle-right.png (100%) create mode 100644 dali-toolkit/internal/controls/model3d-view/model3d-view-impl.cpp create mode 100644 dali-toolkit/internal/controls/model3d-view/model3d-view-impl.h create mode 100644 dali-toolkit/internal/controls/model3d-view/obj-loader.cpp create mode 100644 dali-toolkit/internal/controls/model3d-view/obj-loader.h create mode 100644 dali-toolkit/public-api/controls/model3d-view/model3d-view.cpp create mode 100644 dali-toolkit/public-api/controls/model3d-view/model3d-view.h delete mode 100644 dali-toolkit/styles/480x800/images/cursor_handler_drop_center.png delete mode 100644 dali-toolkit/styles/480x800/images/selection_handle_drop_left.png delete mode 100644 dali-toolkit/styles/480x800/images/selection_handle_drop_right.png delete mode 100644 dali-toolkit/styles/720x1280/images/cursor_handler_drop_center.png delete mode 100644 dali-toolkit/styles/720x1280/images/selection_handle_drop_left.png delete mode 100644 dali-toolkit/styles/720x1280/images/selection_handle_drop_right.png delete mode 100644 dali-toolkit/styles/images-common/core_contextual_popup_bg_stroke_color.9.png delete mode 100644 dali-toolkit/styles/images-common/popup_scroll_white.9.png delete mode 100755 dali-toolkit/styles/images-common/selection_handle_ball_left.png delete mode 100755 dali-toolkit/styles/images-common/selection_handle_ball_right.png delete mode 100755 doc/images/dali-modules.png delete mode 100644 docs/content/programming-guide/styling.h diff --git a/automated-tests/src/dali-toolkit/CMakeLists.txt b/automated-tests/src/dali-toolkit/CMakeLists.txt index 2b1858e..f29792b 100644 --- a/automated-tests/src/dali-toolkit/CMakeLists.txt +++ b/automated-tests/src/dali-toolkit/CMakeLists.txt @@ -47,6 +47,7 @@ SET(TC_SOURCES utc-Dali-StyleManager.cpp utc-Dali-SuperBlurView.cpp utc-Dali-Toolkit.cpp + utc-Dali-Model3dView.cpp ) # Append list of test harness files (Won't get parsed for test cases) diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.cpp b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.cpp index d9ea25e..a0a3589 100644 --- a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.cpp +++ b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.cpp @@ -150,6 +150,14 @@ bool TestPlatformAbstraction::IsLoading() } /** + * @copydoc PlatformAbstraction::GetDefaultFontDescription() + */ +void TestPlatformAbstraction::GetDefaultFontDescription( std::string& family, std::string& style ) const +{ + // TODO +} + +/** * @copydoc PlatformAbstraction::GetDefaultFontSize() */ int TestPlatformAbstraction::GetDefaultFontSize() const diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.h b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.h index 3502e70..673e1af 100644 --- a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.h +++ b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-platform-abstraction.h @@ -139,6 +139,11 @@ public: virtual bool IsLoading(); /** + * @copydoc PlatformAbstraction::GetDefaultFontDescription() + */ + virtual void GetDefaultFontDescription( std::string& family, std::string& style ) const; + + /** * @copydoc PlatformAbstraction::GetDefaultFontSize() */ virtual int GetDefaultFontSize() const; diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.cpp b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.cpp index e35ce05..0aee8ec 100644 --- a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.cpp +++ b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.cpp @@ -21,6 +21,7 @@ // EXTERNAL INCLUDES #include #include +#include namespace Dali { @@ -50,10 +51,10 @@ public: bool RestoreAfterFocusLost() const; void SetRestoreAfterFocusLost( bool toggle ); void NotifyCursorPosition(); + int GetCursorPosition(); void SetCursorPosition( unsigned int cursorPosition ); - unsigned int GetCursorPosition() const; - void SetSurroundingText( const std::string& text ); - const std::string& GetSurroundingText() const; + void SetSurroundingText( std::string text ); + std::string GetSurroundingText(); public: // Signals ImfManagerSignalType& ActivatedSignal() { return mActivatedSignal; } @@ -77,6 +78,7 @@ private: bool mRestoreAfterFocusLost:1; ///< Whether the keyboard needs to be restored (activated ) after focus regained. bool mIdleCallbackConnected:1; ///< Whether the idle callback is already connected. + std::vector mKeyEvents; ///< Stores key events to be sent from idle call-back. ImfManagerSignalType mActivatedSignal; ImfEventSignalType mEventSignal; @@ -118,9 +120,10 @@ Dali::ImfManager ImfManager::Get() ImfManager::ImfManager( /*Ecore_X_Window ecoreXwin*/ ) : mIMFCursorPosition( 0 ), - mSurroundingText(), + mSurroundingText(""), mRestoreAfterFocusLost( false ), - mIdleCallbackConnected( false ) + mIdleCallbackConnected( false ), + mKeyEvents() { CreateContext( /*ecoreXwin*/ ); ConnectCallbacks(); @@ -175,22 +178,22 @@ void ImfManager::NotifyCursorPosition() { } -void ImfManager::SetCursorPosition( unsigned int cursorPosition ) +int ImfManager::GetCursorPosition() { - mIMFCursorPosition = static_cast< int >( cursorPosition ); + return mIMFCursorPosition; } -unsigned int ImfManager::GetCursorPosition() const +void ImfManager::SetCursorPosition( unsigned int cursorPosition ) { - return static_cast( mIMFCursorPosition ); + mIMFCursorPosition = ( int )cursorPosition; } -void ImfManager::SetSurroundingText( const std::string& text ) +void ImfManager::SetSurroundingText( std::string text ) { mSurroundingText = text; } -const std::string& ImfManager::GetSurroundingText() const +std::string ImfManager::GetSurroundingText() { return mSurroundingText; } @@ -217,6 +220,11 @@ ImfManager ImfManager::Get() return Internal::Adaptor::ImfManager::Get(); } +ImfContext ImfManager::GetContext() +{ + return NULL; +} + void ImfManager::Activate() { Internal::Adaptor::ImfManager::GetImplementation(*this).Activate(); @@ -252,17 +260,17 @@ void ImfManager::SetCursorPosition( unsigned int SetCursorPosition ) Internal::Adaptor::ImfManager::GetImplementation(*this).SetCursorPosition( SetCursorPosition ); } -unsigned int ImfManager::GetCursorPosition() const +int ImfManager::GetCursorPosition() { return Internal::Adaptor::ImfManager::GetImplementation(*this).GetCursorPosition(); } -void ImfManager::SetSurroundingText( const std::string& text ) +void ImfManager::SetSurroundingText( std::string text ) { Internal::Adaptor::ImfManager::GetImplementation(*this).SetSurroundingText( text ); } -const std::string& ImfManager::GetSurroundingText() const +std::string ImfManager::GetSurroundingText() { return Internal::Adaptor::ImfManager::GetImplementation(*this).GetSurroundingText(); } diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.h b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.h index d90e9d4..842078b 100644 --- a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.h +++ b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-imf-manager.h @@ -34,198 +34,171 @@ class ImfManager; } } +typedef void* ImfContext; + /** * @brief The ImfManager class - * * Specifically manages the ecore input method framework which enables the virtual or hardware keyboards. */ class ImfManager : public BaseHandle { public: - /** - * @brief Events that are generated by the IMF. - */ enum ImfEvent { - VOID, ///< No event - PREEDIT, ///< Pre-Edit changed - COMMIT, ///< Commit recieved - DELETESURROUNDING, ///< Event to delete a range of characters from the string - GETSURROUNDING ///< Event to query string and cursor position + VOID, + PREEDIT, + COMMIT, + DELETESURROUNDING, + GETSURROUNDING }; /** - * @brief This structure is used to pass on data from the IMF regarding predictive text. + * This structure is used to pass on data from the IMF regarding predictive text. */ struct ImfEventData { /** - * @brief Default Constructor. + * Default Constructor. */ ImfEventData() - : predictiveString(), - eventName( VOID ), + : eventName( VOID ), + predictiveString(""), cursorOffset( 0 ), numberOfChars ( 0 ) { }; /** - * @brief Constructor - * + * Constructor * @param[in] aEventName The name of the event from the IMF. * @param[in] aPredictiveString The pre-edit or commit string. * @param[in] aCursorOffset Start position from the current cursor position to start deleting characters. * @param[in] aNumberOfChars The number of characters to delete from the cursorOffset. */ - ImfEventData( ImfEvent aEventName, const std::string& aPredictiveString, int aCursorOffset, int aNumberOfChars ) - : predictiveString( aPredictiveString ), - eventName( aEventName ), - cursorOffset( aCursorOffset ), - numberOfChars( aNumberOfChars ) + ImfEventData(ImfEvent aEventName, const std::string& aPredictiveString, int aCursorOffset,int aNumberOfChars ) + : eventName(aEventName), predictiveString(aPredictiveString), cursorOffset( aCursorOffset ), numberOfChars( aNumberOfChars ) { } // Data - std::string predictiveString; ///< The pre-edit or commit string. - ImfEvent eventName; ///< The name of the event from the IMF. - int cursorOffset; ///< Start position from the current cursor position to start deleting characters. - int numberOfChars; ///< number of characters to delete from the cursorOffset. + ImfEvent eventName; // The name of the event from the IMF. + std::string predictiveString; // The pre-edit or commit string. + int cursorOffset; // Start position from the current cursor position to start deleting characters. + int numberOfChars; //number of characters to delete from the cursorOffset. }; /** - * @brief Data required by IMF from the callback + * Data required my IMF from the callback */ struct ImfCallbackData { - /** - * @brief Constructor - */ - ImfCallbackData() - : currentText(), - cursorPosition( 0 ), - update( false ), - preeditResetRequired( false ) + ImfCallbackData( ) + : update( false ), cursorPosition( 0 ), preeditResetRequired ( false ) { } - /** - * @brief Constructor - * @param[in] aUpdate True if cursor position needs to be updated - * @param[in] aCursorPosition new position of cursor - * @param[in] aCurrentText current text string - * @param[in] aPreeditResetRequired flag if preedit reset is required. - */ - ImfCallbackData( bool aUpdate, int aCursorPosition, const std::string& aCurrentText, bool aPreeditResetRequired ) - : currentText( aCurrentText ), - cursorPosition( aCursorPosition ), - update( aUpdate ), - preeditResetRequired( aPreeditResetRequired ) + ImfCallbackData(bool aUpdate, int aCursorPosition, std::string aCurrentText, bool aPreeditResetRequired ) + : update(aUpdate), cursorPosition(aCursorPosition), currentText( aCurrentText ), preeditResetRequired( aPreeditResetRequired ) { } - std::string currentText; ///< current text string - int cursorPosition; ///< new position of cursor - bool update :1; ///< if cursor position needs to be updated - bool preeditResetRequired :1; ///< flag if preedit reset is required. + bool update; // if cursor position needs to be updated + int cursorPosition; // new position of cursor + std::string currentText; // current text string + bool preeditResetRequired; // flag if preedit reset is required. }; - typedef Signal< void (ImfManager&) > ImfManagerSignalType; ///< Keyboard actived signal - typedef Signal< ImfCallbackData ( ImfManager&, const ImfEventData& ) > ImfEventSignalType; ///< keyboard events + typedef Signal< void (ImfManager&) > ImfManagerSignalType; + + typedef Signal< ImfCallbackData ( ImfManager&, const ImfEventData& ) > ImfEventSignalType; public: /** - * @brief Retrieve a handle to the instance of ImfManager. + * Retrieve a handle to the instance of ImfManager. * @return A handle to the ImfManager. */ static ImfManager Get(); /** - * @brief Activate the IMF. - * + * Get the current imf context. + * @return current imf context. + */ + ImfContext GetContext(); + + /** + * Activate the IMF. * It means that the text editing is started at somewhere. * If the H/W keyboard isn't connected then it will show the virtual keyboard. */ void Activate(); /** - * @brief Deactivate the IMF. - * + * Deactivate the IMF. * It means that the text editing is finished at somewhere. */ void Deactivate(); /** - * @brief Get the restoration status, which controls if the keyboard is restored after the focus lost then regained. - * + * Get the restoration status, which controls if the keyboard is restored after the focus lost then regained. * If true then keyboard will be restored (activated) after focus is regained. * @return restoration status. */ bool RestoreAfterFocusLost() const; /** - * @brief Set status whether the IMF has to restore the keyboard after losing focus. - * + * Set status whether the IMF has to restore the keyboard after losing focus. * @param[in] toggle True means that keyboard should be restored after focus lost and regained. */ void SetRestoreAfterFocusLost( bool toggle ); /** - * @brief Send message reset the pred-edit state / imf module. - * - * Used to interupt pre-edit state maybe due to a touch input. + * Send message reset the pred-edit state / imf module. Used to interupt pre-edit state maybe due to a touch input. */ void Reset(); /** - * @brief Notifies IMF context that the cursor position has changed, required for features like auto-capitalisation. + * Notifies IMF context that the cursor position has changed, required for features like auto-capitalisation */ void NotifyCursorPosition(); /** - * @brief Sets cursor position stored in VirtualKeyboard, this is required by the IMF context. - * + * Sets cursor position stored in VirtualKeyboard, this is required by the IMF context * @param[in] cursorPosition position of cursor */ void SetCursorPosition( unsigned int cursorPosition ); /** - * @brief Gets cursor position stored in VirtualKeyboard, this is required by the IMF context. - * + * Gets cursor position stored in VirtualKeyboard, this is required by the IMF context * @return current position of cursor */ - unsigned int GetCursorPosition() const; + int GetCursorPosition(); /** - * @brief Method to store the string required by the IMF, this is used to provide predictive word suggestions. - * + * Method to store the string required by the IMF, this is used to provide predictive word suggestions. * @param[in] text The text string surrounding the current cursor point. */ - void SetSurroundingText( const std::string& text ); + void SetSurroundingText( std::string text ); /** - * @brief Gets current text string set within the IMF manager, this is used to offer predictive suggestions. - * + * Gets current text string set within the IMF manager, this is used to offer predictive suggestions * @return current position of cursor */ - const std::string& GetSurroundingText() const; + std::string GetSurroundingText(); public: // Signals /** - * @brief This is emitted when the virtual keyboard is connected to or the hardware keyboard is activated. - * + * This is emitted when the virtual keyboard is connected to or the hardware keyboard is activated. * @return The IMF Activated signal. */ ImfManagerSignalType& ActivatedSignal(); /** - * @brief This is emitted when the IMF manager receives an event from the IMF. - * + * This is emitted when the IMF manager receives an event from the IMF * @return The Event signal containing the event data. */ ImfEventSignalType& EventReceivedSignal(); @@ -233,23 +206,20 @@ public: // Construction & Destruction /** - * @brief Constructor. + * Constructor */ ImfManager(); /** - * @brief Destructor - * - * This is non-virtual since derived Handle types must not contain data or virtual methods. + * Non virtual destructor. */ ~ImfManager(); /** - * @brief This constructor is used by ImfManager::Get(). - * + * This constructor is used by ImfManager::Get(). * @param[in] imfManager A pointer to the imf Manager. */ - explicit ImfManager( Internal::Adaptor::ImfManager* imfManager ); + ImfManager( Internal::Adaptor::ImfManager* imfManager ); }; } // namespace Dali diff --git a/automated-tests/src/dali-toolkit/utc-Dali-ItemView.cpp b/automated-tests/src/dali-toolkit/utc-Dali-ItemView.cpp index 2c49895..b85524d 100644 --- a/automated-tests/src/dali-toolkit/utc-Dali-ItemView.cpp +++ b/automated-tests/src/dali-toolkit/utc-Dali-ItemView.cpp @@ -704,11 +704,11 @@ int UtcDaliItemViewReplaceItemsP(void) for( unsigned int i = 0u; i < 10; ++i ) { - Actor child = view.GetItem( i ); + Actor child = view.GetChildAt( i ); Actor newActor = Actor::New(); newActor.SetName("Replaced"); - replaceList.push_back( Item( i, newActor ) ); + replaceList.push_back( Item( view.GetItemId(child), newActor ) ); } if( !replaceList.empty() ) diff --git a/automated-tests/src/dali-toolkit/utc-Dali-Model3dView.cpp b/automated-tests/src/dali-toolkit/utc-Dali-Model3dView.cpp new file mode 100644 index 0000000..15737f4 --- /dev/null +++ b/automated-tests/src/dali-toolkit/utc-Dali-Model3dView.cpp @@ -0,0 +1,212 @@ +/* + * Copyright (c) 2015 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +#include +#include +#include +#include +#include + + +using namespace Dali; +using namespace Dali::Toolkit; + + +void model_view_startup(void) +{ + test_return_value = TET_UNDEF; +} + +void model_view_cleanup(void) +{ + test_return_value = TET_PASS; +} + +namespace +{ +const char * TEST_OBJ_FILE_NAME = "Dino.obj"; +const char * TEST_MTL_FILE_NAME = "Dino.mtl"; +//const char * TEST_IMG_PATH = ""; +} + +// Negative test case for a method +int UtcDaliModelViewUninitialized(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliModel3dViewUninitialized"); + + Toolkit::Model3dView view; + + try + { + // New() must be called to create a Model3dView or it wont be valid. + Actor a = Actor::New(); + view.Add( a ); + DALI_TEST_CHECK( false ); + } + catch (Dali::DaliException& e) + { + // Tests that a negative test of an assertion succeeds + DALI_TEST_PRINT_ASSERT( e ); + DALI_TEST_CHECK(!view); + } + END_TEST; +} + +// Positive test case for a method +int UtcDaliModelViewNew(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliModel3dViewNew"); + + Toolkit::Model3dView view = Toolkit::Model3dView::New(); + DALI_TEST_CHECK( view ); + + Toolkit::Model3dView view2 = Toolkit::Model3dView::New("","",""); + DALI_TEST_CHECK( view2 ); + END_TEST; +} + +// Positive test case for a method +int UtcDaliModelViewDownCast(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliModelViewDownCast"); + + Toolkit::Model3dView view = Toolkit::Model3dView::New(); + BaseHandle handle(view); + + Toolkit::Model3dView modelView = Toolkit::Model3dView::DownCast( handle ); + DALI_TEST_CHECK( view ); + DALI_TEST_CHECK( modelView ); + DALI_TEST_CHECK( modelView == view ); + END_TEST; +} + + +// Positive test case for a method +int UtcDaliModelViewPropertyNames(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliModel3dViewPropertyNames"); + + Toolkit::Model3dView view = Toolkit::Model3dView::New(); + DALI_TEST_CHECK( view ); + + view.SetProperty( Model3dView::Property::GEOMETRY_URL, Dali::Property::Value( TEST_OBJ_FILE_NAME ) ); + Property::Value val = view.GetProperty( Model3dView::Property::GEOMETRY_URL ); + std::string obj_file_name; + DALI_TEST_CHECK( val.Get( obj_file_name ) ); + DALI_TEST_EQUALS( obj_file_name, TEST_OBJ_FILE_NAME, TEST_LOCATION ); + + view.SetProperty( Model3dView::Property::MATERIAL_URL, Dali::Property::Value( TEST_MTL_FILE_NAME ) ); + val = view.GetProperty( Model3dView::Property::MATERIAL_URL ); + DALI_TEST_CHECK( val.Get( obj_file_name ) ); + DALI_TEST_EQUALS( obj_file_name, TEST_MTL_FILE_NAME, TEST_LOCATION ); + + //modelView.SetProperty( Model3dView::Property::MTL_URL, Dali::Property::Value( mtlUrl ) ); + //modelView.SetProperty( Model3dView::Property::IMAGES_URL, Dali::Property::Value( imagesUrl ) ); + + END_TEST; +} + +// Positive test case for a method +int UtcDaliModelViewAddRemove(void) +{ + ToolkitTestApplication application; + tet_infoline(" UtcDaliModel3dViewAddRemove"); + + Toolkit::Model3dView view = Toolkit::Model3dView::New(); + DALI_TEST_CHECK( view ); + + Actor actor = Actor::New(); + DALI_TEST_CHECK( !actor.OnStage() ); + + + view.SetParentOrigin(ParentOrigin::CENTER); + view.SetSize(Stage::GetCurrent().GetSize()); + view.Add(actor); + Stage::GetCurrent().Add(view); + + DALI_TEST_CHECK( actor.OnStage() ); + + view.Remove(actor); + + DALI_TEST_CHECK( !actor.OnStage() ); + END_TEST; +} + + +int UtcDaliModelCopyAndAssignment(void) +{ + ToolkitTestApplication application; + + Model3dView view = Toolkit::Model3dView::New(); + DALI_TEST_CHECK( view ); + + Model3dView copy( view ); + DALI_TEST_CHECK( view == copy ); + + Model3dView assign; + DALI_TEST_CHECK( ! assign ); + + assign = copy; + DALI_TEST_CHECK( assign == view ); + + END_TEST; +} + +int UtcDaliModelTypeRegistry(void) +{ + ToolkitTestApplication application; + + TypeRegistry typeRegistry = TypeRegistry::Get(); + DALI_TEST_CHECK( typeRegistry ); + + TypeInfo typeInfo = typeRegistry.GetTypeInfo( "Model3dView" ); + DALI_TEST_CHECK( typeInfo ); + + BaseHandle handle = typeInfo.CreateInstance(); + DALI_TEST_CHECK( handle ); + + Model3dView view = Model3dView::DownCast( handle ); + DALI_TEST_CHECK( view ); + + END_TEST; +} + +int UtcDaliModelOnSizeSet(void) +{ + ToolkitTestApplication application; + + Model3dView view = Toolkit::Model3dView::New(); + + Stage::GetCurrent().Add( view ); + + application.SendNotification(); + application.Render(); + + Vector3 size( 200.0f, 300.0f, 0.0f ); + view.SetSize( size ); + + application.SendNotification(); + application.Render(); + + DALI_TEST_EQUALS( view.GetCurrentSize(), size, TEST_LOCATION ); + + END_TEST; +} diff --git a/automated-tests/src/dali-toolkit/utc-Dali-ScrollView.cpp b/automated-tests/src/dali-toolkit/utc-Dali-ScrollView.cpp index 3f9879e..cf3e163 100644 --- a/automated-tests/src/dali-toolkit/utc-Dali-ScrollView.cpp +++ b/automated-tests/src/dali-toolkit/utc-Dali-ScrollView.cpp @@ -882,7 +882,6 @@ int UtcDaliToolkitScrollViewScrollSensitive(void) // Set up a scrollView... ScrollView scrollView = ScrollView::New(); - scrollView.SetOvershootEnabled(true); Stage::GetCurrent().Add( scrollView ); Vector2 stageSize = Stage::GetCurrent().GetSize(); scrollView.SetSize(stageSize); @@ -1094,7 +1093,6 @@ int UtcDaliToolkitScrollViewOvershoot(void) // Set up a scrollView... ScrollView scrollView = ScrollView::New(); - scrollView.SetOvershootEnabled(true); Stage::GetCurrent().Add( scrollView ); Vector2 stageSize = Stage::GetCurrent().GetSize(); scrollView.SetSize(stageSize); @@ -2287,63 +2285,3 @@ int UtcDaliToolkitScrollViewConstraintsWrap(void) END_TEST; } - -// Non-API test (so no P or N variant). -int UtcDaliToolkitScrollViewGesturePageLimit(void) -{ - ToolkitTestApplication application; - tet_infoline( " UtcDaliToolkitScrollViewGesturePageLimit" ); - - // Set up a scrollView. - ScrollView scrollView = ScrollView::New(); - - // Do not rely on stage size for UTC tests. - Vector2 pageSize( 720.0f, 1280.0f ); - scrollView.SetResizePolicy( ResizePolicy::FIXED, Dimension::ALL_DIMENSIONS ); - scrollView.SetSize( pageSize ); - scrollView.SetParentOrigin( ParentOrigin::CENTER ); - scrollView.SetAnchorPoint( AnchorPoint::CENTER ); - scrollView.SetPosition( 0.0f, 0.0f, 0.0f ); - - // Position rulers. - // We set the X ruler to fixed to give us pages to snap to. - Dali::Toolkit::FixedRuler* rulerX = new Dali::Toolkit::FixedRuler( pageSize.width ); - // Note: The 3x page width is arbitary, but we need enough to show that we are - // capping page movement by the page limiter, and not the domain. - rulerX->SetDomain( Dali::Toolkit::RulerDomain( 0.0f, pageSize.width * 3.0f, false ) ); - Dali::Toolkit::RulerPtr rulerY = new Dali::Toolkit::DefaultRuler(); - rulerY->Disable(); - scrollView.SetRulerX( rulerX ); - scrollView.SetRulerY( rulerY ); - - scrollView.SetWrapMode( false ); - scrollView.SetScrollSensitive( true ); - - Stage::GetCurrent().Add( scrollView ); - - // Set up a gesture to perform. - Vector2 startPos( 50.0f, 0.0f ); - Vector2 direction( -5.0f, 0.0f ); - int frames = 200; - - // Force starting position. - scrollView.ScrollTo( startPos, 0.0f ); - Wait( application ); - - // Deliberately skip the "Finished" part of the gesture, so we can read the coordinates before the snap begins. - Vector2 currentPos( PerformGestureDiagonalSwipe( application, startPos, direction, frames - 1, false ) ); - - // Confirm the final X coord has not moved more than one page from the start X position. - DALI_TEST_GREATER( ( startPos.x + pageSize.width ), scrollView.GetCurrentScrollPosition().x, TEST_LOCATION ); - - // Finish the gesture and wait for the snap. - currentPos += direction; - SendPan( application, Gesture::Finished, currentPos ); - // We add RENDER_FRAME_INTERVAL on to wait for an extra frame (for the last "finished" gesture to complete first. - Wait( application, RENDER_DELAY_SCROLL + RENDER_FRAME_INTERVAL ); - - // Confirm the final X coord has snapped to exactly one page ahead of the start page. - DALI_TEST_EQUALS( pageSize.width, scrollView.GetCurrentScrollPosition().x, Math::MACHINE_EPSILON_0, TEST_LOCATION ); - - END_TEST; -} diff --git a/automated-tests/src/dali-toolkit/utc-Dali-TextField.cpp b/automated-tests/src/dali-toolkit/utc-Dali-TextField.cpp index ef8f86d..ea126d4 100644 --- a/automated-tests/src/dali-toolkit/utc-Dali-TextField.cpp +++ b/automated-tests/src/dali-toolkit/utc-Dali-TextField.cpp @@ -705,8 +705,8 @@ int utcDaliTextFieldEvent02(void) // Send some taps and check the cursor positions. // Try to tap at the beginning. - application.ProcessEvent( GenerateTap( Gesture::Possible, 1u, 1u, Vector2( 1.f, 25.0f ) ) ); - application.ProcessEvent( GenerateTap( Gesture::Started, 1u, 1u, Vector2( 1.f, 25.0f ) ) ); + application.ProcessEvent( GenerateTap( Gesture::Possible, 1u, 1u, Vector2( 3.f, 25.0f ) ) ); + application.ProcessEvent( GenerateTap( Gesture::Started, 1u, 1u, Vector2( 3.f, 25.0f ) ) ); // Render and notify application.SendNotification(); @@ -718,8 +718,8 @@ int utcDaliTextFieldEvent02(void) DALI_TEST_EQUALS( position2, position4, TEST_LOCATION ); // Should be in the same position2. // Tap away from the start position. - application.ProcessEvent( GenerateTap( Gesture::Possible, 1u, 1u, Vector2( 16.f, 25.0f ) ) ); - application.ProcessEvent( GenerateTap( Gesture::Started, 1u, 1u, Vector2( 16.0f, 25.0f ) ) ); + application.ProcessEvent( GenerateTap( Gesture::Possible, 1u, 1u, Vector2( 13.f, 25.0f ) ) ); + application.ProcessEvent( GenerateTap( Gesture::Started, 1u, 1u, Vector2( 13.0f, 25.0f ) ) ); // Render and notify application.SendNotification(); @@ -743,7 +743,7 @@ int utcDaliTextFieldEvent02(void) DALI_TEST_EQUALS( position2, position6, TEST_LOCATION );// Should be in the same position2. - // Should not be a renderer. + // Should not be renderer. DALI_TEST_EQUALS( offscreenRoot.GetChildCount(), 1u, TEST_LOCATION ); // The camera actor only. END_TEST; diff --git a/build/tizen/configure.ac b/build/tizen/configure.ac index c43a47c..77c33f0 100644 --- a/build/tizen/configure.ac +++ b/build/tizen/configure.ac @@ -30,7 +30,6 @@ AC_SUBST(DALI_TOOLKIT_VERSION) PKG_CHECK_MODULES(DALICORE, dali-core) PKG_CHECK_MODULES(DALI, dali) -PKG_CHECK_MODULES(FEEDBACK, feedback) DALI_TOOLKIT_CFLAGS=-DPLATFORM_TIZEN diff --git a/build/tizen/dali-toolkit/Makefile.am b/build/tizen/dali-toolkit/Makefile.am index fee4845..948b4cf 100644 --- a/build/tizen/dali-toolkit/Makefile.am +++ b/build/tizen/dali-toolkit/Makefile.am @@ -16,18 +16,17 @@ # Build the Dali Toolkit library -toolkit_images_dir = ../../../dali-toolkit/styles/images-common +toolkit_images_dir = ../../../dali-toolkit/images toolkit_sounds_dir = ../../../dali-toolkit/sounds toolkit_src_dir = ../../../dali-toolkit/internal public_api_src_dir = ../../../dali-toolkit/public-api devel_api_src_dir = ../../../dali-toolkit/devel-api toolkit_styles_dir = $(STYLE_DIR) -toolkit_style_images_dir = $(STYLE_DIR)/images +include ../../../dali-toolkit/images/file.list include ../../../dali-toolkit/sounds/file.list include ../../../dali-toolkit/styles/file.list -include ../../../dali-toolkit/styles/images-common/file.list include ../../../dali-toolkit/internal/file.list include ../../../dali-toolkit/public-api/file.list include ../../../dali-toolkit/devel-api/file.list @@ -50,16 +49,12 @@ libdali_toolkit_la_SOURCES = \ dalistyledir = ${dataReadOnlyDir}/toolkit/styles/ dalistyle_DATA = ${dali_toolkit_style_files} -dalistyleimagesdir = ${dataReadOnlyDir}/toolkit/styles/images/ -dalistyleimages_DATA = ${dali_toolkit_style_images} - libdali_toolkit_la_DEPENDENCIES = libdali_toolkit_la_CXXFLAGS = -DDALI_COMPILATION \ -DDALI_IMAGE_DIR="\"${daliimagedir}\"" \ -DDALI_SOUND_DIR="\"${dalisounddir}\"" \ -DDALI_STYLE_DIR="\"${dalistyledir}\"" \ - -DDALI_STYLE_IMAGE_DIR="\"${dalistyleimagesdir}\"" \ -DDALI_DATA_READ_ONLY_DIR="\"${dataReadOnlyDir}\"" \ -Werror -Wall \ -I../../../ \ @@ -68,16 +63,14 @@ libdali_toolkit_la_CXXFLAGS = -DDALI_COMPILATION \ $(DALI_CFLAGS) \ $(DLOG_CFLAGS) \ $(FRIBIDI_CFLAGS) \ - $(HTMLCXX_CFLAGS) \ - $(FEEDBACK_CFLAGS) + $(HTMLCXX_CFLAGS) libdali_toolkit_la_LIBADD = \ $(DALICORE_LIBS) \ $(DALI_LIBS) \ $(DLOG_LIBS) \ $(FRIBIDI_LIBS) \ - $(HTMLCXX_LIBS) \ - $(FEEDBACK_LIBS) + $(HTMLCXX_LIBS) # Install headers @@ -133,6 +126,7 @@ publicapibuttonsdir = $(publicapicontrolsdir)/buttons publicapidefaultcontrolsdir = $(publicapicontrolsdir)/default-controls publicapigaussianblurviewdir = $(publicapicontrolsdir)/gaussian-blur-view publicapiimageviewdir = $(publicapicontrolsdir)/image-view +publicapimodel3dviewdir = $(publicapicontrolsdir)/model3d-view publicapiscrollbardir = $(publicapicontrolsdir)/scroll-bar publicapiscrollabledir = $(publicapicontrolsdir)/scrollable publicapiscrollviewdir = $(publicapicontrolsdir)/scrollable/scroll-view @@ -152,6 +146,7 @@ publicapidefaultcontrols_HEADERS = $(public_api_default_controls_header_file publicapigaussianblurview_HEADERS = $(public_api_gaussian_blur_view_header_files) publicapiimageview_HEADERS = $(public_api_image_view_header_files) publicapiitemview_HEADERS = $(public_api_item_view_header_files) +publicapimodel3dview_HEADERS = $(public_api_model3d_view_header_files) publicapiscrollbar_HEADERS = $(public_api_scroll_bar_header_files) publicapiscrollable_HEADERS = $(public_api_scrollable_header_files) publicapiscrollview_HEADERS = $(public_api_scroll_view_header_files) diff --git a/dali-toolkit/dali-toolkit.h b/dali-toolkit/dali-toolkit.h index a8a3e1f..7f40633 100644 --- a/dali-toolkit/dali-toolkit.h +++ b/dali-toolkit/dali-toolkit.h @@ -31,6 +31,7 @@ #include #include #include +#include #include #include #include diff --git a/dali-toolkit/devel-api/controls/text-controls/text-selection-popup.h b/dali-toolkit/devel-api/controls/text-controls/text-selection-popup.h index f82203e..4eec4c1 100644 --- a/dali-toolkit/devel-api/controls/text-controls/text-selection-popup.h +++ b/dali-toolkit/devel-api/controls/text-controls/text-selection-popup.h @@ -92,7 +92,6 @@ public: POPUP_PRESSED_IMAGE, ///< name "popup-pressed-image", The image to use for the option when pressed, type STRING POPUP_FADE_IN_DURATION, ///< name "popup-fade-in-duration", The duration of the fade-in animation, type FLOAT POPUP_FADE_OUT_DURATION, ///< name "popup-fade-out-duration", The duration of the fade-out animation, type FLOAT - POPUP_BACKGROUND_IMAGE, ///< name "popup-background-image", The background image, type MAP }; }; diff --git a/dali-toolkit/devel-api/controls/text-controls/text-selection-toolbar.h b/dali-toolkit/devel-api/controls/text-controls/text-selection-toolbar.h index 0d25c56..2fbf611 100644 --- a/dali-toolkit/devel-api/controls/text-controls/text-selection-toolbar.h +++ b/dali-toolkit/devel-api/controls/text-controls/text-selection-toolbar.h @@ -62,10 +62,7 @@ public: { enum { - MAX_SIZE = PROPERTY_START_INDEX, ///< name "max-size", The maximum size the Popup can be, type VECTOR2 - ENABLE_OVERSHOOT, ///< name "enable-overshoot", Whether the overshoot image is enabled, type BOOLEAN - SCROLL_BAR_PADDING, ///< name "scroll-bar-padding", The padding used to position the scroll bar, type VECTOR2 - SCROLL_VIEW ///< name "scroll-view", Properties to set on scroll view type Property::Map + MAX_SIZE = PROPERTY_START_INDEX ///< name "max-size", The maximum size the Popup can be, type VECTOR2 }; }; diff --git a/dali-toolkit/styles/images-common/00_popup_bg.9.png b/dali-toolkit/images/00_popup_bg.9.png similarity index 100% rename from dali-toolkit/styles/images-common/00_popup_bg.9.png rename to dali-toolkit/images/00_popup_bg.9.png diff --git a/dali-toolkit/styles/images-common/00_popup_bg.png b/dali-toolkit/images/00_popup_bg.png similarity index 100% rename from dali-toolkit/styles/images-common/00_popup_bg.png rename to dali-toolkit/images/00_popup_bg.png diff --git a/dali-toolkit/styles/images-common/00_popup_bottom_bg.png b/dali-toolkit/images/00_popup_bottom_bg.png similarity index 100% rename from dali-toolkit/styles/images-common/00_popup_bottom_bg.png rename to dali-toolkit/images/00_popup_bottom_bg.png diff --git a/dali-toolkit/styles/images-common/00_popup_bubble_bg.png b/dali-toolkit/images/00_popup_bubble_bg.png similarity index 100% rename from dali-toolkit/styles/images-common/00_popup_bubble_bg.png rename to dali-toolkit/images/00_popup_bubble_bg.png diff --git a/dali-toolkit/styles/images-common/00_popup_bubble_tail_bottom.png b/dali-toolkit/images/00_popup_bubble_tail_bottom.png similarity index 100% rename from dali-toolkit/styles/images-common/00_popup_bubble_tail_bottom.png rename to dali-toolkit/images/00_popup_bubble_tail_bottom.png diff --git a/dali-toolkit/styles/images-common/00_popup_button_bg.png b/dali-toolkit/images/00_popup_button_bg.png similarity index 100% rename from dali-toolkit/styles/images-common/00_popup_button_bg.png rename to dali-toolkit/images/00_popup_button_bg.png diff --git a/dali-toolkit/styles/images-common/00_popup_button_pressed.png b/dali-toolkit/images/00_popup_button_pressed.png similarity index 100% rename from dali-toolkit/styles/images-common/00_popup_button_pressed.png rename to dali-toolkit/images/00_popup_button_pressed.png diff --git a/dali-toolkit/styles/images-common/B16-8_TTS_focus.png b/dali-toolkit/images/B16-8_TTS_focus.png similarity index 100% rename from dali-toolkit/styles/images-common/B16-8_TTS_focus.png rename to dali-toolkit/images/B16-8_TTS_focus.png diff --git a/dali-toolkit/styles/images-common/button-disabled.9.png b/dali-toolkit/images/button-disabled.9.png similarity index 100% rename from dali-toolkit/styles/images-common/button-disabled.9.png rename to dali-toolkit/images/button-disabled.9.png diff --git a/dali-toolkit/styles/images-common/button-down-disabled.9.png b/dali-toolkit/images/button-down-disabled.9.png similarity index 100% rename from dali-toolkit/styles/images-common/button-down-disabled.9.png rename to dali-toolkit/images/button-down-disabled.9.png diff --git a/dali-toolkit/styles/images-common/button-down.9.png b/dali-toolkit/images/button-down.9.png similarity index 100% rename from dali-toolkit/styles/images-common/button-down.9.png rename to dali-toolkit/images/button-down.9.png diff --git a/dali-toolkit/styles/images-common/button-up.9.png b/dali-toolkit/images/button-up.9.png similarity index 100% rename from dali-toolkit/styles/images-common/button-up.9.png rename to dali-toolkit/images/button-up.9.png diff --git a/dali-toolkit/styles/images-common/checkbox-selected-diabled.png b/dali-toolkit/images/checkbox-selected-diabled.png similarity index 100% rename from dali-toolkit/styles/images-common/checkbox-selected-diabled.png rename to dali-toolkit/images/checkbox-selected-diabled.png diff --git a/dali-toolkit/styles/images-common/checkbox-selected.png b/dali-toolkit/images/checkbox-selected.png similarity index 100% rename from dali-toolkit/styles/images-common/checkbox-selected.png rename to dali-toolkit/images/checkbox-selected.png diff --git a/dali-toolkit/styles/images-common/checkbox-unselected-disabled.png b/dali-toolkit/images/checkbox-unselected-disabled.png similarity index 100% rename from dali-toolkit/styles/images-common/checkbox-unselected-disabled.png rename to dali-toolkit/images/checkbox-unselected-disabled.png diff --git a/dali-toolkit/styles/images-common/checkbox-unselected.png b/dali-toolkit/images/checkbox-unselected.png similarity index 100% rename from dali-toolkit/styles/images-common/checkbox-unselected.png rename to dali-toolkit/images/checkbox-unselected.png diff --git a/dali-toolkit/styles/images-common/copy_paste_icon_clipboard.png b/dali-toolkit/images/copy_paste_icon_clipboard.png similarity index 100% rename from dali-toolkit/styles/images-common/copy_paste_icon_clipboard.png rename to dali-toolkit/images/copy_paste_icon_clipboard.png diff --git a/dali-toolkit/styles/images-common/copy_paste_icon_copy.png b/dali-toolkit/images/copy_paste_icon_copy.png similarity index 100% rename from dali-toolkit/styles/images-common/copy_paste_icon_copy.png rename to dali-toolkit/images/copy_paste_icon_copy.png diff --git a/dali-toolkit/styles/images-common/copy_paste_icon_cut.png b/dali-toolkit/images/copy_paste_icon_cut.png similarity index 100% rename from dali-toolkit/styles/images-common/copy_paste_icon_cut.png rename to dali-toolkit/images/copy_paste_icon_cut.png diff --git a/dali-toolkit/styles/images-common/copy_paste_icon_paste.png b/dali-toolkit/images/copy_paste_icon_paste.png similarity index 100% rename from dali-toolkit/styles/images-common/copy_paste_icon_paste.png rename to dali-toolkit/images/copy_paste_icon_paste.png diff --git a/dali-toolkit/styles/images-common/copy_paste_icon_select.png b/dali-toolkit/images/copy_paste_icon_select.png similarity index 100% rename from dali-toolkit/styles/images-common/copy_paste_icon_select.png rename to dali-toolkit/images/copy_paste_icon_select.png diff --git a/dali-toolkit/styles/images-common/copy_paste_icon_select_all.png b/dali-toolkit/images/copy_paste_icon_select_all.png similarity index 100% rename from dali-toolkit/styles/images-common/copy_paste_icon_select_all.png rename to dali-toolkit/images/copy_paste_icon_select_all.png diff --git a/dali-toolkit/images/core_contextual_popup_bg_stroke_color.9.png b/dali-toolkit/images/core_contextual_popup_bg_stroke_color.9.png deleted file mode 100644 index 136abcec428fe9f2785ffa3bb9b70ca03a21d6d2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 459 zcmeAS@N?(olHy`uVBq!ia0vp^+91rq1|%QG79IdnY)RhkE)4%caKYZ?lYt_f1s;*b z3=G`DAk4@xYmNj^kiEpy*OmP~rywVvh-2fFwG0f55uPrNArXh)-rSgVC_v=c$NHEY zwp{HFi(PE-E(K?+H7?!VyXgJIi{ge}Y3{GDNqNKy`HL4zyK?0!dp?k{aBe%GFMm?? zyW9@{lRJyoMtwVUIG5F;u0?kK2A2ox=VsN{zUTB-dSh|mqwSq*zF#LjeBfdGlilFE zU6B7Y9`+dZSx(MUM(H}SWvvps-=v(2aFSws^Kct)nRESAr|KMU!JPiJjQKCt^Ozm# zV@)}@!Y98`N20UA<%VHH>Aw=z2NRhUeNP4X*L*lRwUbZ+;QplR=!-VDYKP%{aYVUw>k&kw15p!EU2)gXZO+#P|x<2Pd49 z{_!!(?C(*(&pt~@fw3=t-hsop>FHd?YL^n@IW`@ROY_-e+&qlgPp9j>wZV1Uvwq3qU@w=n6~#G>Jp`dtG`xdw!5 zKoy60UVY%jA)sd;xOE8V#<%Xk6`gvLhJkwrs3j6BmJK w#nM|cOD_Wq0DboE4S2Rfmk0J^Sb6|_05z9fHC>Kal>h($07*qoM6N<$g7gF6j{pDw literal 0 HcmV?d00001 diff --git a/dali-toolkit/images/selection_handle_right.png b/dali-toolkit/images/selection_handle_right.png new file mode 100755 index 0000000000000000000000000000000000000000..ea5ac918c02963c35f915749bab16446b280d798 GIT binary patch literal 553 zcmV+^0@nSBP)50k%m* zK~z}7&Dg(c6j2n%@y|>e4QQ8Ei3moqPvM_JR)Q}e#Ai_7MbIKme25exij7IcKst3- zkOX5Hv{11Sl4Fs(n#5UmCT4f;4^A`p&-rry%suB65fS!OsHbVn;VLfTEKa4iZ}^BV zmhlvunkfFrKWri*<|ASyB6g#`cGH;oG>2hU2dEPf-S~fX(_BXeIuQ{Iar|0Hb2kE- ziiousoz{|%zkrI0Lp_C;xL~w;k89Z8|FJyOX%b6gfRTJGC7%O<9$?n^G@E=@Ui(h8 zr%u%w>ZTuE8|vXQcJ^;sTQD$#+f`?%P2I(TEo)nW^Es_hfw`Q3;7V>lmvTBo@Fh2( zpSf+B5}z~T`Cj5vMnGF7-em;zwoKVUE?Oxf;v7CSNP|ZHbZlTXgVlM3jsCTNlmXDg z{%a2tc$4CiECRG0+-q@l?k9!=0orpsZUJTy&wj@shn})YyclEV@ftVqV-QewiK5iu zI@U)Bvz~lxSCwN1*~zww4a4kaMD&gUq?hIzT8^n>{esnM!-7?$F?Z?~tcoK9jMKQ4 rN_sOmgVU+)E4I>)ZW&LSmh^rB#SCc;?6`>|00000NkvXXu0mjffy3*n literal 0 HcmV?d00001 diff --git a/dali-toolkit/styles/images-common/selection_marker_left.png b/dali-toolkit/images/selection_marker_left.png similarity index 100% rename from dali-toolkit/styles/images-common/selection_marker_left.png rename to dali-toolkit/images/selection_marker_left.png diff --git a/dali-toolkit/styles/images-common/selection_marker_right.png b/dali-toolkit/images/selection_marker_right.png similarity index 100% rename from dali-toolkit/styles/images-common/selection_marker_right.png rename to dali-toolkit/images/selection_marker_right.png diff --git a/dali-toolkit/styles/images-common/slider-popup-arrow.png b/dali-toolkit/images/slider-popup-arrow.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-popup-arrow.png rename to dali-toolkit/images/slider-popup-arrow.png diff --git a/dali-toolkit/styles/images-common/slider-popup.9.png b/dali-toolkit/images/slider-popup.9.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-popup.9.png rename to dali-toolkit/images/slider-popup.9.png diff --git a/dali-toolkit/styles/images-common/slider-popup.png b/dali-toolkit/images/slider-popup.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-popup.png rename to dali-toolkit/images/slider-popup.png diff --git a/dali-toolkit/styles/images-common/slider-skin-handle.png b/dali-toolkit/images/slider-skin-handle.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-skin-handle.png rename to dali-toolkit/images/slider-skin-handle.png diff --git a/dali-toolkit/styles/images-common/slider-skin-progress.9.png b/dali-toolkit/images/slider-skin-progress.9.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-skin-progress.9.png rename to dali-toolkit/images/slider-skin-progress.9.png diff --git a/dali-toolkit/styles/images-common/slider-skin-progress.png b/dali-toolkit/images/slider-skin-progress.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-skin-progress.png rename to dali-toolkit/images/slider-skin-progress.png diff --git a/dali-toolkit/styles/images-common/slider-skin.9.png b/dali-toolkit/images/slider-skin.9.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-skin.9.png rename to dali-toolkit/images/slider-skin.9.png diff --git a/dali-toolkit/styles/images-common/slider-skin.png b/dali-toolkit/images/slider-skin.png similarity index 100% rename from dali-toolkit/styles/images-common/slider-skin.png rename to dali-toolkit/images/slider-skin.png diff --git a/dali-toolkit/styles/images-common/text-input-selection-handle-left-press.png b/dali-toolkit/images/text-input-selection-handle-left-press.png similarity index 100% rename from dali-toolkit/styles/images-common/text-input-selection-handle-left-press.png rename to dali-toolkit/images/text-input-selection-handle-left-press.png diff --git a/dali-toolkit/styles/images-common/text-input-selection-handle-left.png b/dali-toolkit/images/text-input-selection-handle-left.png similarity index 100% rename from dali-toolkit/styles/images-common/text-input-selection-handle-left.png rename to dali-toolkit/images/text-input-selection-handle-left.png diff --git a/dali-toolkit/styles/images-common/text-input-selection-handle-right-press.png b/dali-toolkit/images/text-input-selection-handle-right-press.png similarity index 100% rename from dali-toolkit/styles/images-common/text-input-selection-handle-right-press.png rename to dali-toolkit/images/text-input-selection-handle-right-press.png diff --git a/dali-toolkit/styles/images-common/text-input-selection-handle-right.png b/dali-toolkit/images/text-input-selection-handle-right.png similarity index 100% rename from dali-toolkit/styles/images-common/text-input-selection-handle-right.png rename to dali-toolkit/images/text-input-selection-handle-right.png diff --git a/dali-toolkit/internal/builder/builder-impl.cpp b/dali-toolkit/internal/builder/builder-impl.cpp index 66cfa25..2d8aeb1 100644 --- a/dali-toolkit/internal/builder/builder-impl.cpp +++ b/dali-toolkit/internal/builder/builder-impl.cpp @@ -1362,7 +1362,6 @@ Builder::Builder() defaultDirs[ TOKEN_STRING(DALI_IMAGE_DIR) ] = DALI_IMAGE_DIR; defaultDirs[ TOKEN_STRING(DALI_SOUND_DIR) ] = DALI_SOUND_DIR; defaultDirs[ TOKEN_STRING(DALI_STYLE_DIR) ] = DALI_STYLE_DIR; - defaultDirs[ TOKEN_STRING(DALI_STYLE_IMAGE_DIR) ] = DALI_STYLE_IMAGE_DIR; AddConstants( defaultDirs ); } diff --git a/dali-toolkit/internal/controls/image-view/image-view-impl.cpp b/dali-toolkit/internal/controls/image-view/image-view-impl.cpp index 3773078..7cfdb07 100644 --- a/dali-toolkit/internal/controls/image-view/image-view-impl.cpp +++ b/dali-toolkit/internal/controls/image-view/image-view-impl.cpp @@ -250,7 +250,6 @@ void ImageView::OnStageConnection( int depth ) if( mImage ) { AttachImage(); - Control::OnStageConnection( depth ); } } diff --git a/dali-toolkit/internal/controls/model3d-view/model3d-view-impl.cpp b/dali-toolkit/internal/controls/model3d-view/model3d-view-impl.cpp new file mode 100644 index 0000000..84780be --- /dev/null +++ b/dali-toolkit/internal/controls/model3d-view/model3d-view-impl.cpp @@ -0,0 +1,675 @@ +/* + * Copyright (c) 2015 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +// CLASS HEADER +#include "model3d-view-impl.h" + +// EXTERNAL INCLUDES +#include +#include +#include +#include +#include +#include +#include +#include + +// INTERNAL INCLUDES +#include + +namespace Dali +{ + +namespace Toolkit +{ + +namespace Internal +{ + +namespace +{ + +// Type registration +BaseHandle Create() +{ + return Toolkit::Model3dView::New(); +} + +// Setup properties, signals and actions using the type-registry. +DALI_TYPE_REGISTRATION_BEGIN( Toolkit::Model3dView, Toolkit::Control, Create ); + +DALI_PROPERTY_REGISTRATION( Toolkit, Model3dView, "geometry-url", STRING, GEOMETRY_URL) +DALI_PROPERTY_REGISTRATION( Toolkit, Model3dView, "material-url", STRING, MATERIAL_URL) +DALI_PROPERTY_REGISTRATION( Toolkit, Model3dView, "images-url", STRING, IMAGES_URL) +DALI_PROPERTY_REGISTRATION( Toolkit, Model3dView, "illumination-type", INTEGER, ILLUMINATION_TYPE) +DALI_PROPERTY_REGISTRATION( Toolkit, Model3dView, "texture0-url", STRING, TEXTURE0_URL) +DALI_PROPERTY_REGISTRATION( Toolkit, Model3dView, "texture1-url", STRING, TEXTURE1_URL) +DALI_PROPERTY_REGISTRATION( Toolkit, Model3dView, "texture2-url", STRING, TEXTURE2_URL) + +DALI_ANIMATABLE_PROPERTY_REGISTRATION( Toolkit, Model3dView, "light-position", VECTOR3, LIGHT_POSITION) + +DALI_TYPE_REGISTRATION_END() + + +#define MAKE_SHADER(A)#A + +// Diffuse illumination shader + +const char* SIMPLE_VERTEX_SHADER = MAKE_SHADER( + attribute highp vec3 aPosition;\n + attribute highp vec2 aTexCoord;\n + attribute highp vec3 aNormal;\n + varying mediump vec3 vIllumination;\n + uniform mediump vec3 uSize;\n + uniform mediump mat4 uMvpMatrix;\n + uniform mediump mat4 uModelView;\n + uniform mediump mat3 uNormalMatrix; + uniform mediump mat4 uObjectMatrix;\n + uniform mediump vec3 uLightPosition;\n + \n + void main()\n + {\n + vec4 vertexPosition = vec4(aPosition*min(uSize.x, uSize.y), 1.0);\n + vertexPosition = uObjectMatrix * vertexPosition;\n + vertexPosition = uMvpMatrix * vertexPosition;\n + \n + //Illumination in Model-View space - Transform attributes and uniforms\n + vec4 vertPos4 = uModelView * vec4(aPosition.xyz, 1.0);\n + vec3 vertPos = vec3(vertPos4) / vertPos4.w;\n + \n + vec3 normalInterp = uNormalMatrix * aNormal;\n + \n + vec4 lightPos4 = uModelView * vec4(uLightPosition, 1.0);\n + vec3 lightPos = vec3(lightPos4) / lightPos4.w;\n + \n + vec3 vecToLight = normalize( lightPos.xyz - vertPos.xyz );\n + \n + float lightDiffuse = dot( vecToLight, normalInterp );\n + lightDiffuse = max(0.0,lightDiffuse);\n + vIllumination = vec3(lightDiffuse * 0.5 + 0.5);\n + \n + gl_Position = vertexPosition;\n + }\n +); + +const char* SIMPLE_FRAGMENT_SHADER = MAKE_SHADER( + precision mediump float;\n + varying mediump vec3 vIllumination;\n + uniform lowp vec4 uColor;\n + \n + void main()\n + {\n + gl_FragColor.rgb = vIllumination.rgb * uColor.rgb;\n + gl_FragColor.a = uColor.a;\n + }\n +); + +// Diffuse and specular illumination shader with albedo texture + +const char* VERTEX_SHADER = MAKE_SHADER( + attribute highp vec3 aPosition;\n + attribute highp vec2 aTexCoord;\n + attribute highp vec3 aNormal;\n + varying mediump vec2 vTexCoord;\n + varying mediump vec3 vIllumination;\n + varying mediump float vSpecular;\n + uniform mediump vec3 uSize;\n + uniform mediump mat4 uMvpMatrix;\n + uniform mediump mat4 uModelView; + uniform mediump mat3 uNormalMatrix; + uniform mediump mat4 uObjectMatrix;\n + uniform mediump vec3 uLightPosition;\n + \n + void main() + {\n + vec4 vertexPosition = vec4(aPosition*min(uSize.x, uSize.y), 1.0);\n + vertexPosition = uObjectMatrix * vertexPosition;\n + vertexPosition = uMvpMatrix * vertexPosition;\n + \n + //Illumination in Model-View space - Transform attributes and uniforms\n + vec4 vertPos4 = uModelView * vec4(aPosition.xyz, 1.0);\n + vec3 vertPos = vec3(vertPos4) / vertPos4.w;\n + \n + vec4 lightPos4 = uModelView * vec4(uLightPosition, 1.0);\n + vec3 lightPos = vec3(lightPos4) / lightPos4.w;\n + \n + vec3 normalInterp = normalize(uNormalMatrix * aNormal);\n + \n + vec3 vecToLight = normalize( lightPos.xyz - vertPos.xyz );\n + vec3 viewDir = normalize(-vertPos); + \n + vec3 halfVector = normalize(viewDir + vecToLight); + \n + float lightDiffuse = dot( vecToLight, normalInterp );\n + lightDiffuse = max(0.0,lightDiffuse);\n + vIllumination = vec3(lightDiffuse * 0.5 + 0.5);\n + \n + // this is blinn phong + //float specAngle = max(dot(halfVector, normalInterp), 0.0);\n + //vSpecular = pow(specAngle, 16.0);\n + \n + // this is phong (for comparison) + vec3 reflectDir = reflect(-vecToLight, normalInterp); + float specAngle = max(dot(reflectDir, viewDir), 0.0); + // note that the exponent is different here + vSpecular = pow(specAngle, 16.0/4.0); + \n + vTexCoord = aTexCoord;\n + gl_Position = vertexPosition;\n + }\n +); + +const char* FRAGMENT_SHADER = MAKE_SHADER( + precision mediump float;\n + varying mediump vec2 vTexCoord;\n + varying mediump vec3 vIllumination;\n + varying mediump float vSpecular;\n + uniform sampler2D sDiffuse;\n + uniform lowp vec4 uColor;\n + \n + void main()\n + {\n + vec4 texture = texture2D( sDiffuse, vTexCoord );\n + gl_FragColor.rgb = vIllumination.rgb * texture.rgb * uColor.rgb + vSpecular * 0.3;\n + gl_FragColor.a = texture.a * uColor.a;\n + }\n +); + +// Diffuse and specular illumination shader with albedo texture, normal map and gloss map shader + +const char* NRMMAP_VERTEX_SHADER = MAKE_SHADER( + attribute highp vec3 aPosition;\n + attribute highp vec2 aTexCoord;\n + attribute highp vec3 aNormal;\n + attribute highp vec3 aTangent;\n + attribute highp vec3 aBiNormal;\n + varying mediump vec2 vTexCoord;\n + varying mediump vec3 vLightDirection;\n + varying mediump vec3 vHalfVector;\n + uniform mediump vec3 uSize;\n + uniform mediump mat4 uMvpMatrix;\n + uniform mediump mat4 uModelView; + uniform mediump mat3 uNormalMatrix; + uniform mediump mat4 uObjectMatrix;\n + uniform mediump vec3 uLightPosition;\n + \n + void main() + {\n + vec4 vertexPosition = vec4(aPosition*min(uSize.x, uSize.y), 1.0);\n + vertexPosition = uObjectMatrix * vertexPosition;\n + vertexPosition = uMvpMatrix * vertexPosition;\n + \n + vTexCoord = aTexCoord;\n + \n + vec3 vNormal = normalize(uNormalMatrix * aNormal);\n + vec3 vTangent = normalize(uNormalMatrix * aTangent);\n + vec3 vBiNormal = normalize(uNormalMatrix * aBiNormal);\n + \n + vec4 vertPos4 = uModelView * vec4(aPosition.xyz, 1.0);\n + vec3 vertPos = vec3(vertPos4) / vertPos4.w;\n + \n + vec4 lightPos4 = uModelView * vec4(uLightPosition, 1.0);\n + vec3 lightPos = vec3(lightPos4) / lightPos4.w;\n + \n + vec3 vecToLight = lightPos - vertPos; + vLightDirection.x = dot(vecToLight, vTangent); + vLightDirection.y = dot(vecToLight, vBiNormal); + vLightDirection.z = dot(vecToLight, vNormal); + vLightDirection = normalize(vLightDirection); + \n + vec3 viewDir = normalize(vertPos); + \n + vec3 halfVector = normalize(viewDir + vecToLight); + vHalfVector.x = dot (halfVector, vTangent); + vHalfVector.y = dot (halfVector, vBiNormal); + vHalfVector.z = dot (halfVector, vNormal); + \n + gl_Position = vertexPosition;\n + + //vHalfVector = aTangent; + }\n +); + +const char* NRMMAP_FRAGMENT_SHADER = MAKE_SHADER( + precision mediump float;\n + varying mediump vec2 vTexCoord;\n + varying mediump vec3 vLightDirection;\n + varying mediump vec3 vHalfVector;\n + uniform sampler2D sDiffuse;\n + uniform sampler2D sNormal;\n + uniform sampler2D sGloss;\n + uniform lowp vec4 uColor;\n + \n + void main()\n + {\n + vec4 texture = texture2D( sDiffuse, vTexCoord );\n + vec4 nrmMap = texture2D( sNormal, vTexCoord ) * 2.0 - 1.0;\n + vec4 glossMap = texture2D( sGloss, vTexCoord );\n + \n + vec3 normalizedLightDirection = normalize(vLightDirection);\n + float lightDiffuse = max( 0.0, dot( nrmMap.xyz, normalizedLightDirection ) );\n + lightDiffuse = lightDiffuse * 0.5 + 0.5;\n + \n + float shininess = pow (max (dot (vHalfVector, nrmMap.xyz), 0.0), 16.0) ; + \n + gl_FragColor.rgb = texture.rgb * uColor.rgb * lightDiffuse + shininess * glossMap.rgb;\n + gl_FragColor.a = texture.a * uColor.a;\n + + //gl_FragColor.rgb = vHalfVector.rgb; + }\n +); + + +} // anonymous namespace + +using namespace Dali; + +void LookAt(Matrix& result, const Vector3& eye, const Vector3& target, const Vector3& up) +{ + Vector3 vZ = target - eye; + vZ.Normalize(); + + Vector3 vX = up.Cross(vZ); + vX.Normalize(); + + Vector3 vY = vZ.Cross(vX); + vY.Normalize(); + + result.SetInverseTransformComponents(vX, vY, vZ, eye); +} + + +Model3dView::Model3dView() + : Control( ControlBehaviour( ACTOR_BEHAVIOUR_NONE ) ) +{ + mTexture0Url = ""; + mTexture1Url = ""; + mTexture2Url = ""; + + mIlluminationType = Toolkit::Model3dView::DIFFUSE_WITH_NORMAL_MAP; + + mCameraFOV = Math::PI_OVER_180 * 45.f; + + mControlSize = Vector2(100.,100.); +} + +Model3dView::~Model3dView() +{ +} + +Toolkit::Model3dView Model3dView::New() +{ + Model3dView* impl = new Model3dView(); + + Dali::Toolkit::Model3dView handle = Dali::Toolkit::Model3dView( *impl ); + + // Second-phase init of the implementation + // This can only be done after the CustomActor connection has been made... + impl->Initialize(); + + return handle; +} + +void Model3dView::SetProperty( BaseObject* object, Property::Index index, const Property::Value& value ) +{ + Toolkit::Model3dView model3dView = Toolkit::Model3dView::DownCast( Dali::BaseHandle( object ) ); + + if( model3dView ) + { + Model3dView& impl( GetImpl( model3dView ) ); + switch( index ) + { + case Toolkit::Model3dView::Property::GEOMETRY_URL: + { + if( value.Get(impl.mObjUrl) ) + { + impl.LoadGeometry(); + impl.CreateGeometry(); + } + break; + } + case Toolkit::Model3dView::Property::MATERIAL_URL: + { + if( value.Get(impl.mMaterialUrl) ) + { + impl.LoadMaterial(); + impl.CreateMaterial(); + } + break; + } + case Toolkit::Model3dView::Property::IMAGES_URL: + { + if( value.Get(impl.mImagesUrl) ) + { + impl.LoadTextures(); + } + break; + } + case Toolkit::Model3dView::Property::ILLUMINATION_TYPE: + { + int illuminationType; + if( value.Get(illuminationType) ) + { + impl.mIlluminationType = Toolkit::Model3dView::IlluminationType(illuminationType); + impl.CreateGeometry(); + impl.CreateMaterial(); + impl.LoadTextures(); + } + break; + } + case Toolkit::Model3dView::Property::TEXTURE0_URL: + { + value.Get(impl.mTexture0Url); + break; + } + case Toolkit::Model3dView::Property::TEXTURE1_URL: + { + value.Get(impl.mTexture1Url); + break; + } + case Toolkit::Model3dView::Property::TEXTURE2_URL: + { + value.Get(impl.mTexture2Url); + break; + } + } + } +} + +Property::Value Model3dView::GetProperty( BaseObject* object, Property::Index index ) +{ + Property::Value value; + + Toolkit::Model3dView model3dView = Toolkit::Model3dView::DownCast( Dali::BaseHandle( object ) ); + + if( model3dView ) + { + Model3dView& impl( GetImpl( model3dView ) ); + switch( index ) + { + case Toolkit::Model3dView::Property::GEOMETRY_URL: + { + value = impl.mObjUrl; + break; + } + case Toolkit::Model3dView::Property::MATERIAL_URL: + { + value = impl.mMaterialUrl; + break; + } + case Toolkit::Model3dView::Property::IMAGES_URL: + { + value = impl.mImagesUrl; + break; + } + case Toolkit::Model3dView::Property::ILLUMINATION_TYPE: + { + value = int(impl.mIlluminationType); + break; + } + case Toolkit::Model3dView::Property::TEXTURE0_URL: + { + value = impl.mTexture0Url; + break; + } + case Toolkit::Model3dView::Property::TEXTURE1_URL: + { + value = impl.mTexture1Url; + break; + } + case Toolkit::Model3dView::Property::TEXTURE2_URL: + { + value = impl.mTexture2Url; + break; + } + } + } + + return value; +} + +///////////////////////////////////////////////////////////// + + +void Model3dView::OnStageConnection( int depth ) +{ + CustomActor self = Self(); + self.AddRenderer( mRenderer ); + + if( mObjLoader.IsSceneLoaded() ) + { + mMesh = mObjLoader.CreateGeometry(mIlluminationType); + + CreateMaterial(); + LoadTextures(); + + mRenderer.SetGeometry( mMesh ); + + //create constraint for lightPosition Property with uLightPosition in the shader + Vector3 lightPosition( 0, 0, 0 ); + Dali::Property::Index lightProperty = mShader.RegisterProperty( "uLightPosition", lightPosition ); + Constraint constraint = Constraint::New( mShader, lightProperty, EqualToConstraint() ); + constraint.AddSource( Source( self, Toolkit::Model3dView::Property::LIGHT_POSITION ) ); + constraint.Apply(); + } +} + +/////////////////////////////////////////////////////////// +// +// Private methods +// + +void Model3dView::OnInitialize() +{ + //Create empty versions of the geometry and material so we always have a Renderer + Geometry mesh = Geometry::New(); + Shader shader = Shader::New( SIMPLE_VERTEX_SHADER, SIMPLE_FRAGMENT_SHADER, (Shader::ShaderHints)(Shader::HINT_REQUIRES_SELF_DEPTH_TEST | Shader::HINT_MODIFIES_GEOMETRY) ); + Material material = Material::New( shader ); + mRenderer = Renderer::New( mesh, material ); +} + +void Model3dView::LoadGeometry() +{ + //Load file in adaptor + std::streampos fileSize; + Dali::Vector fileContent; + + if (FileLoader::ReadFile(mObjUrl,fileSize,fileContent,FileLoader::TEXT)) + { + mObjLoader.ClearArrays(); + + std::string materialUrl; + mObjLoader.Load(fileContent.Begin(), fileSize, materialUrl); + + //Get size information from the obj loaded + mSceneCenter = mObjLoader.GetCenter(); + mSceneSize = mObjLoader.GetSize(); + } + else + { + //Error + } +} + +void Model3dView::LoadMaterial() +{ + //Load file in adaptor + std::streampos fileSize; + Dali::Vector fileContent; + + if( FileLoader::ReadFile(mMaterialUrl, fileSize, fileContent, FileLoader::TEXT) ) + { + mObjLoader.LoadMaterial(fileContent.Begin(), fileSize, mTexture0Url, mTexture1Url, mTexture2Url); + } + else + { + //Error + } +} + +void Model3dView::Load() +{ + LoadGeometry(); + LoadMaterial(); +} + +void Model3dView::OnRelayout( const Vector2& size, RelayoutContainer& container ) +{ + UpdateView(); +} + +void Model3dView::UpdateView() +{ + if( mObjLoader.IsSceneLoaded() ) + { + //The object will always be centred + + Matrix scaleMatrix; + scaleMatrix.SetIdentityAndScale(Vector3(1.0, -1.0, 1.0)); + + mShader.RegisterProperty( "uObjectMatrix", scaleMatrix ); + } +} + +void Model3dView::CreateGeometry() +{ + if( mObjLoader.IsSceneLoaded() ) + { + mMesh = mObjLoader.CreateGeometry(mIlluminationType); + + if( mRenderer ) + { + mRenderer.SetGeometry( mMesh ); + } + } +} + +void Model3dView::UpdateShaderUniforms() +{ + if( mShader ) + { + //Update shader related info, uniforms, etc. for the new shader + UpdateView(); + + Vector3 lightPosition( 0, 0, 0 ); + Dali::Property::Index lightProperty = mShader.RegisterProperty( "uLightPosition", lightPosition ); + + CustomActor self = Self(); + + //create constraint for lightPosition Property with uLightPosition in the shader + if( lightProperty ) + { + Constraint constraint = Constraint::New( mShader, lightProperty, EqualToConstraint() ); + constraint.AddSource( Source( self, Toolkit::Model3dView::Property::LIGHT_POSITION ) ); + constraint.Apply(); + } + } +} + +void Model3dView::CreateMaterial() +{ + if( mObjLoader.IsMaterialLoaded() && (mTexture0Url != "")) + { + if( (mTexture2Url != "") && (mTexture1Url != "") && (mIlluminationType == Toolkit::Model3dView::DIFFUSE_WITH_NORMAL_MAP)) + { + mShader = Shader::New( NRMMAP_VERTEX_SHADER, NRMMAP_FRAGMENT_SHADER, (Shader::ShaderHints)(Shader::HINT_REQUIRES_SELF_DEPTH_TEST | Shader::HINT_MODIFIES_GEOMETRY) ); + } + else if(mIlluminationType == Toolkit::Model3dView::DIFFUSE_WITH_TEXTURE) + { + mShader = Shader::New( VERTEX_SHADER, FRAGMENT_SHADER, (Shader::ShaderHints)(Shader::HINT_REQUIRES_SELF_DEPTH_TEST | Shader::HINT_MODIFIES_GEOMETRY) ); + } + else + { + mShader = Shader::New( SIMPLE_VERTEX_SHADER, SIMPLE_FRAGMENT_SHADER, (Shader::ShaderHints)(Shader::HINT_REQUIRES_SELF_DEPTH_TEST | Shader::HINT_MODIFIES_GEOMETRY) ); + } + } + else + { + mShader = Shader::New( SIMPLE_VERTEX_SHADER, SIMPLE_FRAGMENT_SHADER, (Shader::ShaderHints)(Shader::HINT_REQUIRES_SELF_DEPTH_TEST | Shader::HINT_MODIFIES_GEOMETRY) ); + } + + mMaterial = Material::New( mShader ); + + mMaterial.SetFaceCullingMode(Material::NONE); + + if( mRenderer ) + { + mRenderer.SetMaterial( mMaterial ); + } + + UpdateShaderUniforms(); +} + +void Model3dView::LoadTextures() +{ + if( !mMaterial ) + return ; + + if( mTexture0Url != "" ) + { + std::string imgUrl = mImagesUrl + mTexture0Url; + + //Load textures + Image tex0 = ResourceImage::New( imgUrl ); + if( tex0 ) + { + Sampler sampler = Sampler::New( tex0, "sDiffuse" ); + sampler.SetWrapMode(Sampler::REPEAT,Sampler::REPEAT); + sampler.SetAffectsTransparency(false); + + mMaterial.AddSampler( sampler ); + } + } + + if( (mTexture1Url != "") && (mIlluminationType == Toolkit::Model3dView::DIFFUSE_WITH_NORMAL_MAP) ) + { + std::string imgUrl = mImagesUrl + mTexture1Url; + + //Load textures + Image tex1 = ResourceImage::New( imgUrl ); + if (tex1) + { + Sampler sampler = Sampler::New( tex1, "sNormal" ); + sampler.SetWrapMode(Sampler::REPEAT,Sampler::REPEAT); + sampler.SetAffectsTransparency(false); + sampler.SetFilterMode(Sampler::LINEAR,Sampler::LINEAR); + + mMaterial.AddSampler( sampler ); + } + } + + if( (mTexture2Url != "") && (mIlluminationType == Toolkit::Model3dView::DIFFUSE_WITH_NORMAL_MAP) ) + { + std::string imgUrl = mImagesUrl + mTexture2Url; + + //Load textures + Image tex2 = ResourceImage::New( imgUrl ); + if( tex2 ) + { + Sampler sampler = Sampler::New( tex2, "sGloss" ); + sampler.SetWrapMode(Sampler::REPEAT,Sampler::REPEAT); + sampler.SetAffectsTransparency(false); + sampler.SetFilterMode(Sampler::LINEAR,Sampler::LINEAR); + + mMaterial.AddSampler( sampler ); + } + } +} + +} // namespace Internal +} // namespace Toolkit +} // namespace Dali diff --git a/dali-toolkit/internal/controls/model3d-view/model3d-view-impl.h b/dali-toolkit/internal/controls/model3d-view/model3d-view-impl.h new file mode 100644 index 0000000..2202409 --- /dev/null +++ b/dali-toolkit/internal/controls/model3d-view/model3d-view-impl.h @@ -0,0 +1,195 @@ +#ifndef __DALI_TOOLKIT_INTERNAL_MODEL3D_VIEW_H__ +#define __DALI_TOOLKIT_INTERNAL_MODEL3D_VIEW_H__ + +/* + * Copyright (c) 2015 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +// EXTERNAL INCLUDES +#include + +// INTERNAL INCLUDES +#include +#include +#include + +namespace Dali +{ + +namespace Toolkit +{ + +class Model3dView; + +namespace Internal +{ +/** + * @brief Impl class for Model3dView. + * + * All the geometry loaded with the control is automatically centered and scaled to fit + * the size of all the other controls. So the max is (0.5,0.5) and the min is (-0.5,-0.5) +*/ +class Model3dView : public Control +{ +public: + + /** + * @brief Create a new Model3dView. + * + * @return A public handle to the newly allocated Model3dView. + */ + static Toolkit::Model3dView New(); + + // Properties + + /** + * @brief Called when a property of an object of this type is set. + * + * @param[in] object The object whose property is set. + * @param[in] index The property index. + * @param[in] value The new property value. + */ + static void SetProperty( BaseObject* object, Property::Index index, const Property::Value& value ); + + /** + * @brief Called to retrieve a property of an object of this type. + * + * @param[in] object The object whose property is to be retrieved. + * @param[in] index The property index. + * @return The current value of the property. + */ + static Property::Value GetProperty( BaseObject* object, Property::Index index ); + + /** + * @copydoc Control::OnRelayout + */ + virtual void OnRelayout( const Vector2& size, RelayoutContainer& container ); + + /** + * @brief Called to load both geometry (.obj) and material (.mtl) files + * + */ + void Load(); + +protected: + + /** + * @brief Construct a new Model3dView. + */ + Model3dView(); + + /** + * A reference counted object may only be deleted by calling Unreference() + */ + virtual ~Model3dView(); + +private: + + /** + * @copydoc Toolkit::Control::OnInitialize() + */ + virtual void OnInitialize(); + + /** + * @copydoc CustomActorImpl::OnStageConnection() + */ + virtual void OnStageConnection( int depth ); + +private: + + /** + * @brief Load geometry (.obj) from file + */ + void LoadGeometry(); + + /** + * @brief Load material (.mtl) from file + */ + void LoadMaterial(); + + /** + * @brief Create Geometry class from the loaded geometry + */ + void CreateGeometry(); + + /** + * @brief Create Material and Shader classes from the loaded material + */ + void CreateMaterial(); + + /** + * @brief Load samplers and add them to Material + */ + void LoadTextures(); + + /** + * @brief Set matrix to shader to orientate geometry + */ + void UpdateView(); + + /** + * @brief Update shader uniforms + */ + void UpdateShaderUniforms(); + + + ObjLoader mObjLoader; + + //Properties + std::string mObjUrl; + std::string mMaterialUrl; + std::string mImagesUrl; + std::string mTexture0Url; + std::string mTexture1Url; + std::string mTexture2Url; + Vector3 mLightPosition; + float mCameraFOV; + Toolkit::Model3dView::IlluminationType mIlluminationType; + + //Size + Vector2 mControlSize; + Vector3 mSceneCenter; + Vector3 mSceneSize; + + //Render members + Shader mShader; + Material mMaterial; + Geometry mMesh; + Renderer mRenderer; +}; + +} // namespace Internal + +// Helpers for public-api forwarding methods +inline Toolkit::Internal::Model3dView& GetImpl( Toolkit::Model3dView& obj ) +{ + DALI_ASSERT_ALWAYS(obj); + Dali::RefObject& handle = obj.GetImplementation(); + return static_cast(handle); +} + +inline const Toolkit::Internal::Model3dView& GetImpl( const Toolkit::Model3dView& obj ) +{ + DALI_ASSERT_ALWAYS(obj); + const Dali::RefObject& handle = obj.GetImplementation(); + return static_cast(handle); +} + +} // namespace Toolkit + +} // namespace Dali + +#endif // __DALI_TOOLKIT_INTERNAL_MODEL_VIEW_H__ diff --git a/dali-toolkit/internal/controls/model3d-view/obj-loader.cpp b/dali-toolkit/internal/controls/model3d-view/obj-loader.cpp new file mode 100644 index 0000000..c950b9d --- /dev/null +++ b/dali-toolkit/internal/controls/model3d-view/obj-loader.cpp @@ -0,0 +1,587 @@ +/* + * Copyright (c) 2015 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +// CLASS HEADER +#include "obj-loader.h" + +// EXTERNAL INCLUDES +#include +#include +#include + +namespace Dali +{ + +namespace Toolkit +{ + +namespace Internal +{ + +using namespace Dali; + +ObjLoader::ObjLoader() +{ + mSceneLoaded = false; + mMaterialLoaded = false; + mSceneAABB.Init(); +} + +ObjLoader::~ObjLoader() +{ + ClearArrays(); +} + +bool ObjLoader::IsSceneLoaded() +{ + return mSceneLoaded; +} + +bool ObjLoader::IsMaterialLoaded() +{ + return mMaterialLoaded; +} + +//TODO: Use a function that can generate more than one normal/tangent per vertex (using angle) +void ObjLoader::CalculateTangentArray(const Dali::Vector& vertex, + const Dali::Vector& texcoord, + Dali::Vector& triangle, + Dali::Vector& normal, + Dali::Vector& tangent) +{ + normal.Clear(); + normal.Resize(vertex.Size()); + + Vector3 *tan1 = new Vector3[vertex.Size() * 2]; + + memset(tan1, 0, normal.Size() * sizeof(Vector3) * 2); + memset(&normal[0], 0, normal.Size() * sizeof(Vector3) * 2); + + for (unsigned long a = 0; a < triangle.Size(); a++) + { + Vector3 Tangent, Bitangent, Normal; + + const Vector3& v0 = vertex[triangle[a].pntIndex[0]]; + const Vector3& v1 = vertex[triangle[a].pntIndex[1]]; + const Vector3& v2 = vertex[triangle[a].pntIndex[2]]; + + Vector3 Edge1 = v1 - v0; + Vector3 Edge2 = v2 - v0; + + Normal = Edge1.Cross(Edge2); + + const Vector2& w0 = texcoord[triangle[a].texIndex[0]]; + const Vector2& w1 = texcoord[triangle[a].texIndex[1]]; + const Vector2& w2 = texcoord[triangle[a].texIndex[2]]; + + float DeltaU1 = w1.x - w0.x; + float DeltaV1 = w1.y - w0.y; + float DeltaU2 = w2.x - w0.x; + float DeltaV2 = w2.y - w0.y; + + float f = 1.0f / (DeltaU1 * DeltaV2 - DeltaU2 * DeltaV1); + + Tangent.x = f * (DeltaV2 * Edge1.x - DeltaV1 * Edge2.x); + Tangent.y = f * (DeltaV2 * Edge1.y - DeltaV1 * Edge2.y); + Tangent.z = f * (DeltaV2 * Edge1.z - DeltaV1 * Edge2.z); + + tan1[triangle[a].pntIndex[0]] += Tangent; + tan1[triangle[a].pntIndex[1]] += Tangent; + tan1[triangle[a].pntIndex[2]] += Tangent; + + normal[triangle[a].pntIndex[0]] += Normal; + normal[triangle[a].pntIndex[1]] += Normal; + normal[triangle[a].pntIndex[2]] += Normal; + } + + for (unsigned long a = 0; a < triangle.Size(); a++) + { + for (unsigned long j = 0; j < 3; j++) + { + triangle[a].nrmIndex[j] = triangle[a].pntIndex[j]; + } + } + + for (unsigned long a = 0; a < normal.Size(); a++) + { + normal[a].Normalize(); + + const Vector3& n = normal[a]; + const Vector3& t = tan1[a]; + + // Gram-Schmidt orthogonalize + Vector3 calc = t - n * n.Dot(t); + calc.Normalize(); + tangent[a] = Vector3(calc.x,calc.y,calc.z); + } + + delete[] tan1; +} + + +void ObjLoader::CenterAndScale(bool center, Dali::Vector& points) +{ + BoundingVolume newAABB; + + Vector3 sceneSize = GetSize(); + + float biggestDimension = sceneSize.x; + if( sceneSize.y > biggestDimension ) + { + biggestDimension = sceneSize.y; + } + if( sceneSize.z > biggestDimension ) + { + biggestDimension = sceneSize.z; + } + + + newAABB.Init(); + for( unsigned int ui = 0; ui < points.Size(); ++ui) + { + points[ui] = points[ui] - GetCenter(); + points[ui] = points[ui] / biggestDimension; + newAABB.ConsiderNewPointInVolume(points[ui]); + } + + mSceneAABB = newAABB; +} + +void ObjLoader::CreateGeometryArray(Dali::Vector & vertices, + Dali::Vector & textures, + Dali::Vector & verticesExt, + Dali::Vector & indices) +{ + //If we don't have tangents, calculate them + //we need to recalculate the normals too, because we need just one normal,tangent, bitangent per vertex + //TODO: Use a better function to calculate tangents + if( mTangents.Size() == 0 ) + { + mTangents.Resize(mNormals.Size()); + mBiTangents.Resize(mNormals.Size()); + CalculateTangentArray(mPoints, mTextures, mTriangles, mNormals, mTangents); + for (unsigned int ui = 0 ; ui < mNormals.Size() ; ++ui ) + { + mBiTangents[ui] = mNormals[ui].Cross(mTangents[ui]); + } + } + + //Check the number of points textures and normals + if ((mPoints.Size() == mTextures.Size()) && (mTextures.Size() == mNormals.Size())) + { + //We create the vertices array. For now we just copy points info + for (unsigned int ui = 0 ; ui < mPoints.Size() ; ++ui ) + { + Vertex vertex; + vertex.position = mPoints[ui]; + vertices.PushBack(vertex); + + textures.PushBack(Vector2()); + verticesExt.PushBack(VertexExt()); + } + + //We copy the indices + for (unsigned int ui = 0 ; ui < mTriangles.Size() ; ++ui ) + { + for (int j = 0 ; j < 3 ; ++j) + { + indices.PushBack(mTriangles[ui].pntIndex[j]); + + vertices[mTriangles[ui].pntIndex[j]].normal = mNormals[mTriangles[ui].nrmIndex[j]]; + + textures[mTriangles[ui].pntIndex[j]] = mTextures[mTriangles[ui].texIndex[j]]; + + verticesExt[mTriangles[ui].pntIndex[j]].tangent = mTangents[mTriangles[ui].nrmIndex[j]]; + verticesExt[mTriangles[ui].pntIndex[j]].bitangent = mBiTangents[mTriangles[ui].nrmIndex[j]]; + } + } + } + else + { + //We have to normalize the arrays so we can draw we just one index array + for (unsigned int ui = 0 ; ui < mTriangles.Size() ; ++ui ) + { + for (int j = 0 ; j < 3 ; ++j) + { + Vertex vertex; + vertex.position = mPoints[mTriangles[ui].pntIndex[j]]; + vertex.normal = mNormals[mTriangles[ui].nrmIndex[j]]; + vertices.PushBack(vertex); + + textures.PushBack(mTextures[mTriangles[ui].texIndex[j]]); + + VertexExt vertexExt; + vertexExt.tangent = mTangents[mTriangles[ui].nrmIndex[j]]; + vertexExt.bitangent = mBiTangents[mTriangles[ui].nrmIndex[j]]; + verticesExt.PushBack(vertexExt); + } + } + } +} + +bool ObjLoader::Load(char* objBuffer, std::streampos fileSize, std::string& materialFile) +{ + Vector3 point; + Vector2 texture; + std::string vet[4], name; + int ptIdx[4]; + int nrmIdx[4]; + int texIdx[4]; + TriIndex triangle,triangle2; + int pntAcum = 0, texAcum = 0, nrmAcum = 0; + bool iniObj = false; + int face = 0; + + //Init AABB for the file + mSceneAABB.Init(); + + std::string strMatActual; + + std::string input = objBuffer; + std::istringstream ss(input); + ss.imbue(std::locale("C")); + + + std::string line; + std::getline(ss, line); + + while (std::getline(ss, line)) + { + std::istringstream isline(line, std::istringstream::in); + std::string tag; + + isline >> tag; + + if (tag == "v") + { + //Two different objects in the same file + isline >> point.x; + isline >> point.y; + isline >> point.z; + mPoints.PushBack(point); + + mSceneAABB.ConsiderNewPointInVolume(point); + } + else if (tag == "vn") + { + isline >> point.x; + isline >> point.y; + isline >> point.z; + + mNormals.PushBack(point); + } + else if (tag == "#_#tangent") + { + isline >> point.x; + isline >> point.y; + isline >> point.z; + + mTangents.PushBack(point); + } + else if (tag == "#_#binormal") + { + isline >> point.x; + isline >> point.y; + isline >> point.z; + + mBiTangents.PushBack(point); + } + else if (tag == "vt") + { + isline >> texture.x; + isline >> texture.y; + + texture.y = 1.0-texture.y; + mTextures.PushBack(texture); + } + else if (tag == "#_#vt1") + { + isline >> texture.x; + isline >> texture.y; + + texture.y = 1.0-texture.y; + mTextures2.PushBack(texture); + } + else if (tag == "s") + { + } + else if (tag == "f") + { + if (!iniObj) + { + //name assign + + iniObj = true; + } + + int numIndices = 0; + while( isline >> vet[numIndices] ) + { + numIndices++; + } + + char separator; + char separator2; + //File could not have texture Coordinates + if (strstr(vet[0].c_str(),"//")) + { + for( int i = 0 ; i < numIndices; i++) + { + std::istringstream isindex(vet[i]); + isindex >> ptIdx[i] >> separator >> nrmIdx[i]; + texIdx[i] = 0; + } + } + else if (strstr(vet[0].c_str(),"/")) + { + for( int i = 0 ; i < numIndices; i++) + { + std::istringstream isindex(vet[i]); + isindex >> ptIdx[i] >> separator >> texIdx[i] >> separator2 >> nrmIdx[i]; + } + } + else + { + for( int i = 0 ; i < numIndices; i++) + { + std::istringstream isindex(vet[i]); + isindex >> ptIdx[i]; + texIdx[i] = 0; + nrmIdx[i] = 0; + } + } + + //If it is a triangle + if( numIndices == 3 ) + { + for( int i = 0 ; i < 3; i++) + { + triangle.pntIndex[i] = ptIdx[i] - 1 - pntAcum; + triangle.nrmIndex[i] = nrmIdx[i] - 1 - nrmAcum; + triangle.texIndex[i] = texIdx[i] - 1 - texAcum; + } + mTriangles.PushBack(triangle); + face++; + } + //If on the other hand it is a quad, we will create two triangles + else if( numIndices == 4 ) + { + for( int i = 0 ; i < 3; i++) + { + triangle.pntIndex[i] = ptIdx[i] - 1 - pntAcum; + triangle.nrmIndex[i] = nrmIdx[i] - 1 - nrmAcum; + triangle.texIndex[i] = texIdx[i] - 1 - texAcum; + } + mTriangles.PushBack(triangle); + face++; + + for( int i = 0 ; i < 3; i++) + { + int idx = (i+2) % numIndices; + triangle2.pntIndex[i] = ptIdx[idx] - 1 - pntAcum; + triangle2.nrmIndex[i] = nrmIdx[idx] - 1 - nrmAcum; + triangle2.texIndex[i] = texIdx[idx] - 1 - texAcum; + } + mTriangles.PushBack(triangle2); + face++; + } + } + else if (tag == "usemtl") + { + isline >> strMatActual; + } + else if (tag == "mtllib") + { + isline >> strMatActual; + } + else if (tag == "g") + { + isline >> name; + } + else + { + } + } + + if (iniObj) + { + pntAcum += (int)mPoints.Size(); + texAcum += (int)mTextures.Size(); + nrmAcum += (int)mNormals.Size(); + + CenterAndScale(true, mPoints); + + face = 0; + + mSceneLoaded = true; + + return true; + } + + return false; + +} + +void ObjLoader::LoadMaterial(char* objBuffer, std::streampos fileSize, std::string& texture0Url, std::string& texture1Url, std::string& texture2Url) +{ + float fR,fG,fB; + + std::string info; + + std::string input = objBuffer; + std::istringstream ss(input); + ss.imbue(std::locale("C")); + + std::string line; + std::getline(ss, line); + + while (std::getline(ss, line)) + { + std::istringstream isline(line, std::istringstream::in); + std::string tag; + + isline >> tag; + + if (tag == "newmtl") //name of the material + { + isline >> info; + } + else if (tag == "Kd") //diffuse color + { + isline >> fR >> fG >> fB; + } + else if (tag == "Kd") //Ambient color + { + isline >> fR >> fG >> fB; + } + else if (tag == "Tf") //color + { + } + else if (tag == "Ni") + { + } + else if (tag == "map_Kd") + { + isline >> info; + texture0Url = info; + } + else if (tag == "bump") + { + isline >> info; + texture1Url = info; + } + else if (tag == "map_Ks") + { + isline >> info; + texture2Url = info; + } + } + + mMaterialLoaded = true; +} + +Geometry ObjLoader::CreateGeometry(Toolkit::Model3dView::IlluminationType illuminationType) +{ + Dali::Vector vertices; + Dali::Vector textures; + Dali::Vector verticesExt; + Dali::Vector indices; + + CreateGeometryArray(vertices, textures, verticesExt, indices); + + //All vertices need at least Position and Normal + Property::Map vertexFormat; + vertexFormat["aPosition"] = Property::VECTOR3; + vertexFormat["aNormal"] = Property::VECTOR3; + PropertyBuffer surfaceVertices = PropertyBuffer::New( vertexFormat, vertices.Size() ); + surfaceVertices.SetData( &vertices[0] ); + + Geometry surface = Geometry::New(); + surface.AddVertexBuffer( surfaceVertices ); + + //Some need texture coordinates + if( (illuminationType == Toolkit::Model3dView::DIFFUSE_WITH_NORMAL_MAP ) || (illuminationType == Toolkit::Model3dView::DIFFUSE_WITH_TEXTURE ) ) + { + Property::Map textureFormat; + textureFormat["aTexCoord"] = Property::VECTOR2; + PropertyBuffer extraVertices = PropertyBuffer::New( textureFormat, textures.Size() ); + extraVertices.SetData( &textures[0] ); + + surface.AddVertexBuffer( extraVertices ); + } + + //Some need tangent and bitangent + if( illuminationType == Toolkit::Model3dView::DIFFUSE_WITH_NORMAL_MAP ) + { + Property::Map vertexExtFormat; + vertexExtFormat["aTangent"] = Property::VECTOR3; + vertexExtFormat["aBiNormal"] = Property::VECTOR3; + PropertyBuffer extraVertices = PropertyBuffer::New( vertexExtFormat, verticesExt.Size() ); + extraVertices.SetData( &verticesExt[0] ); + + surface.AddVertexBuffer( extraVertices ); + } + + if (indices.Size()) + { + //Indices + Property::Map indicesVertexFormat; + indicesVertexFormat["aIndices"] = Property::INTEGER; + PropertyBuffer indicesToVertices = PropertyBuffer::New( indicesVertexFormat, indices.Size() ); + indicesToVertices.SetData(&indices[0]); + + surface.SetIndexBuffer ( indicesToVertices ); + } + + surface.SetRequiresDepthTesting(true); + //surface.SetProperty(Geometry::Property::GEOMETRY_HALF_EXTENTS, GetSize() * 0.5); + + vertices.Clear(); + verticesExt.Clear(); + indices.Clear(); + + return surface; +} + +Vector3 ObjLoader::GetCenter() +{ + Vector3 center = GetSize() * 0.5 + mSceneAABB.pointMin; + return center; +} + +Vector3 ObjLoader::GetSize() +{ + Vector3 size = mSceneAABB.pointMax - mSceneAABB.pointMin; + return size; +} + +void ObjLoader::ClearArrays() +{ + mPoints.Clear(); + mTextures.Clear(); + mNormals.Clear(); + mTangents.Clear(); + mBiTangents.Clear(); + + mTriangles.Clear(); + + mSceneLoaded = false; +} + +} // namespace Internal +} // namespace Toolkit +} // namespace Dali diff --git a/dali-toolkit/internal/controls/model3d-view/obj-loader.h b/dali-toolkit/internal/controls/model3d-view/obj-loader.h new file mode 100644 index 0000000..eac63c3 --- /dev/null +++ b/dali-toolkit/internal/controls/model3d-view/obj-loader.h @@ -0,0 +1,157 @@ +#ifndef __DALI_TOOLKIT_INTERNAL_OBJ_LOADER_H__ +#define __DALI_TOOLKIT_INTERNAL_OBJ_LOADER_H__ + +/* + * Copyright (c) 2015 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +// EXTERNAL INCLUDES +#include + +// INTERNAL INCLUDES +#include + + +namespace Dali +{ + +namespace Toolkit +{ + +class ObjLoader; + +namespace Internal +{ +class ObjLoader +{ +public: + + struct TriIndex + { + int pntIndex[3]; + int nrmIndex[3]; + int texIndex[3]; + }; + + struct Vertex + { + Vertex() + {} + + Vertex( const Vector3& position, const Vector3& normal, const Vector2& textureCoord ) + : position( position ), normal( normal ) + {} + + Vector3 position; + Vector3 normal; + }; + + struct VertexExt + { + VertexExt() + {} + + VertexExt( const Vector3& tangent, const Vector3& binormal ) + : tangent( tangent), bitangent (binormal) + {} + + Vector3 tangent; + Vector3 bitangent; + }; + + struct BoundingVolume + { + void Init() + { + pointMin = Vector3(999999.9,999999.9,999999.9); + pointMax = Vector3(-999999.9,-999999.9,-999999.9); + } + + void ConsiderNewPointInVolume(const Vector3& position) + { + pointMin.x = std::min(position.x, pointMin.x); + pointMin.y = std::min(position.y, pointMin.y); + pointMin.z = std::min(position.z, pointMin.z); + + pointMax.x = std::max(position.x, pointMax.x); + pointMax.y = std::max(position.y, pointMax.y); + pointMax.z = std::max(position.z, pointMax.z); + } + + Vector3 pointMin; + Vector3 pointMax; + }; + + ObjLoader(); + virtual ~ObjLoader(); + + bool IsSceneLoaded(); + bool IsMaterialLoaded(); + + bool Load(char* objBuffer, std::streampos fileSize, std::string& materialFile); + + void LoadMaterial(char* objBuffer, std::streampos fileSize, std::string& texture0Url, std::string& texture1Url, std::string& texture2Url); + + Geometry CreateGeometry(Toolkit::Model3dView::IlluminationType illuminationType); + + Vector3 GetCenter(); + Vector3 GetSize(); + + void ClearArrays(); + +private: + + BoundingVolume mSceneAABB; + + bool mSceneLoaded; + bool mMaterialLoaded; + + Dali::Vector mPoints; + Dali::Vector mTextures; + Dali::Vector mTextures2; + Dali::Vector mNormals; + Dali::Vector mTangents; + Dali::Vector mBiTangents; + Dali::Vector mTriangles; + + void CalculateTangentArray(const Dali::Vector& vertex, + const Dali::Vector& texcoord, + Dali::Vector& triangle, + Dali::Vector& normal, + Dali::Vector& tangent); + + void CenterAndScale(bool center, Dali::Vector& points); + + + void CreateGeometryArray(Dali::Vector & vertices, + Dali::Vector & textures, + Dali::Vector & verticesExt, + Dali::Vector & indices); + +}; + + + +} // namespace Internal + +} // namespace Toolkit + +} // namespace Dali + + + + +#endif // __DALI_TOOLKIT_INTERNAL_OBJ_LOADER_H__ diff --git a/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp b/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp index 100f4f0..d2b699b 100755 --- a/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp +++ b/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp @@ -28,6 +28,7 @@ #include #include + // INTERNAL INCLUDES #include @@ -36,7 +37,8 @@ using namespace Dali; namespace { -const char* DEFAULT_INDICATOR_IMAGE_PATH = DALI_IMAGE_DIR "popup_scroll_white.9.png"; +const char* DEFAULT_INDICATOR_IMAGE_PATH = DALI_IMAGE_DIR "popup_scroll.png"; +const Vector4 DEFAULT_INDICATOR_NINE_PATCH_BORDER(4.0f, 9.0f, 7.0f, 11.0f); const float MINIMUM_INDICATOR_HEIGHT(20.0f); // The minimum indicator height for the nine patch border const float DEFAULT_SLIDER_DEPTH(1.0f); const float DEFAULT_INDICATOR_SHOW_DURATION(0.5f); @@ -150,7 +152,6 @@ const char* INDICATOR_HEIGHT_POLICY_NAME[] = {"Variable", "Fixed"}; ScrollBar::ScrollBar(Toolkit::ScrollBar::Direction direction) : Control( ControlBehaviour( REQUIRES_TOUCH_EVENTS | REQUIRES_STYLE_CHANGE_SIGNALS ) ), - mIndicatorShowAlpha(1.0f), mDirection(direction), mScrollableObject(WeakHandleBase()), mPropertyScrollPosition(Property::INVALID_INDEX), @@ -160,11 +161,10 @@ ScrollBar::ScrollBar(Toolkit::ScrollBar::Direction direction) mIndicatorShowDuration(DEFAULT_INDICATOR_SHOW_DURATION), mIndicatorHideDuration(DEFAULT_INDICATOR_HIDE_DURATION), mScrollStart(0.0f), + mIsPanning(false), mCurrentScrollPosition(0.0f), mIndicatorHeightPolicy(Toolkit::ScrollBar::Variable), - mIndicatorFixedHeight(DEFAULT_INDICATOR_FIXED_HEIGHT), - mIsPanning(false), - mIndicatorFirstShow(true) + mIndicatorFixedHeight(DEFAULT_INDICATOR_FIXED_HEIGHT) { } @@ -204,12 +204,11 @@ void ScrollBar::CreateDefaultIndicatorActor() { Image indicatorImage = ResourceImage::New( DEFAULT_INDICATOR_IMAGE_PATH ); ImageActor indicator = ImageActor::New( indicatorImage ); + indicator.SetNinePatchBorder( DEFAULT_INDICATOR_NINE_PATCH_BORDER ); indicator.SetStyle( ImageActor::STYLE_NINE_PATCH ); indicator.SetParentOrigin( ParentOrigin::TOP_LEFT ); indicator.SetAnchorPoint( AnchorPoint::TOP_LEFT ); - indicator.SetColorMode( USE_OWN_MULTIPLY_PARENT_COLOR ); - SetScrollIndicator(indicator); } @@ -219,7 +218,6 @@ void ScrollBar::SetScrollIndicator( Actor indicator ) if( indicator ) { mIndicator = indicator; - mIndicatorFirstShow = true; Self().Add(mIndicator); EnableGestureDetection(Gesture::Type(Gesture::Pan)); @@ -330,22 +328,15 @@ void ScrollBar::ShowIndicator() mAnimation.Reset(); } - if( mIndicatorFirstShow ) - { - // Preserve the alpha value from the stylesheet - mIndicatorShowAlpha = Self().GetCurrentColor().a; - mIndicatorFirstShow = false; - } - if(mIndicatorShowDuration > 0.0f) { mAnimation = Animation::New( mIndicatorShowDuration ); - mAnimation.AnimateTo( Property( mIndicator, Actor::Property::COLOR_ALPHA ), mIndicatorShowAlpha, AlphaFunction::EASE_IN ); + mAnimation.AnimateTo( Property( mIndicator, Actor::Property::COLOR_ALPHA ), 1.0f, AlphaFunction::EASE_IN ); mAnimation.Play(); } else { - mIndicator.SetOpacity(mIndicatorShowAlpha); + mIndicator.SetOpacity(1.0f); } } diff --git a/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.h b/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.h index 1f9691d..23d3fa7 100755 --- a/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.h +++ b/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.h @@ -265,7 +265,6 @@ private: private: Actor mIndicator; ///< Image of scroll indicator. - float mIndicatorShowAlpha; ///< The alpha value when the indicator is fully shown Animation mAnimation; ///< Scroll indicator Show/Hide Animation. Toolkit::ScrollBar::Direction mDirection; ///< The direction of scroll bar (vertical or horizontal) @@ -283,6 +282,7 @@ private: float mScrollStart; ///< Scroll Start position (start of drag) Vector3 mGestureDisplacement; ///< Gesture Displacement. + bool mIsPanning; ///< Whether the scroll bar is being panned. float mCurrentScrollPosition; ///< The current scroll position updated by the pan gesture Toolkit::ScrollBar::IndicatorHeightPolicy mIndicatorHeightPolicy; ///< The height policy of scroll indicator (variable or fixed) @@ -300,9 +300,6 @@ private: Constraint mIndicatorPositionConstraint; Constraint mIndicatorSizeConstraint; Constraint mScrollPositionInCurrentAxisConstraint; - - bool mIsPanning : 1; ///< Whether the scroll bar is being panned. - bool mIndicatorFirstShow : 1; ///< True if the indicator has never been shown }; } // namespace Internal diff --git a/dali-toolkit/internal/controls/scrollable/bouncing-effect-actor.cpp b/dali-toolkit/internal/controls/scrollable/bouncing-effect-actor.cpp index 1f2009a..89eb96e 100644 --- a/dali-toolkit/internal/controls/scrollable/bouncing-effect-actor.cpp +++ b/dali-toolkit/internal/controls/scrollable/bouncing-effect-actor.cpp @@ -39,12 +39,7 @@ namespace Internal namespace { // Bouncing effect is presented by stacked three layers with same color and opacity -const float LAYER_HEIGHTS[3] = -{ - 1.f, - 27.f/42.f, - 13.f/42.f -}; +const Vector3 LAYER_HEIGHTS( 1.f, 27.f/42.f, 13.f/42.f); #define MAKE_SHADER(A)#A @@ -83,7 +78,7 @@ Actor CreateBouncingEffectActor( Property::Index& bouncePropertyIndex ) }; // 4 vertices 2 triangles per layer. The depth interval between each layer is 0.01 VertexPosition vertexData[12] = { - // bottom layer + //bottom layer { Vector3( -0.5f, -0.5f, 0.f ), Vector3( -0.5f, -0.5f, 0.f ) }, { Vector3( 0.5f, -0.5f, 0.f ), Vector3( 0.5f, -0.5f, 0.f ) }, { Vector3( -0.5f, -0.5f, 0.f ), Vector3( -0.5f, -0.5f + LAYER_HEIGHTS[0], 0.f ) }, diff --git a/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.cpp b/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.cpp index b981110..0ed79f9 100644 --- a/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.cpp +++ b/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.cpp @@ -71,6 +71,7 @@ const float DEFAULT_ANCHORING_DURATION = 1.0f; // 1 second const float MILLISECONDS_PER_SECONDS = 1000.0f; +const Vector2 OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE( 720.0f, 42.0f ); const float OVERSHOOT_BOUNCE_ACTOR_RESIZE_THRESHOLD = 180.0f; const Vector4 OVERSHOOT_OVERLAY_NINE_PATCH_BORDER(0.0f, 0.0f, 1.0f, 12.0f); const float DEFAULT_KEYBOARD_FOCUS_SCROLL_DURATION = 0.2f; @@ -89,33 +90,23 @@ float CalculateScrollDistance(Vector2 panDistance, Toolkit::ItemLayout& layout) } // Overshoot overlay constraints -struct OvershootOverlaySizeConstraint +void OvershootOverlaySizeConstraint( Vector3& current, const PropertyInputContainer& inputs ) { - OvershootOverlaySizeConstraint( float height ) - : mOvershootHeight( height ) + const Vector2& parentScrollDirection = inputs[0]->GetVector2(); + const Toolkit::ControlOrientation::Type& layoutOrientation = static_cast(inputs[1]->GetInteger()); + const Vector3& parentSize = inputs[2]->GetVector3(); + + if(Toolkit::IsVertical(layoutOrientation)) { + current.width = fabsf(parentScrollDirection.y) > Math::MACHINE_EPSILON_1 ? parentSize.x : parentSize.y; } - - void operator()( Vector3& current, const PropertyInputContainer& inputs ) + else { - const Vector2& parentScrollDirection = inputs[0]->GetVector2(); - const Toolkit::ControlOrientation::Type& layoutOrientation = static_cast(inputs[1]->GetInteger()); - const Vector3& parentSize = inputs[2]->GetVector3(); - - if(Toolkit::IsVertical(layoutOrientation)) - { - current.width = fabsf(parentScrollDirection.y) > Math::MACHINE_EPSILON_1 ? parentSize.x : parentSize.y; - } - else - { - current.width = fabsf(parentScrollDirection.x) > Math::MACHINE_EPSILON_1 ? parentSize.y : parentSize.x; - } - - current.height = ( current.width > OVERSHOOT_BOUNCE_ACTOR_RESIZE_THRESHOLD ) ? mOvershootHeight : mOvershootHeight*0.5f; + current.width = fabsf(parentScrollDirection.x) > Math::MACHINE_EPSILON_1 ? parentSize.y : parentSize.x; } - float mOvershootHeight; -}; + current.height = ( current.width > OVERSHOOT_BOUNCE_ACTOR_RESIZE_THRESHOLD ) ? OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.height : OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.height*0.5f; +} void OvershootOverlayRotationConstraint( Quaternion& current, const PropertyInputContainer& inputs ) { @@ -289,27 +280,26 @@ Dali::Toolkit::ItemView ItemView::New(ItemFactory& factory) ItemView::ItemView(ItemFactory& factory) : Scrollable( ControlBehaviour( DISABLE_SIZE_NEGOTIATION | REQUIRES_WHEEL_EVENTS | REQUIRES_KEYBOARD_NAVIGATION_SUPPORT ) ), mItemFactory(factory), - mItemsParentOrigin(ParentOrigin::CENTER), - mItemsAnchorPoint(AnchorPoint::CENTER), - mTotalPanDisplacement(Vector2::ZERO), mActiveLayout(NULL), + mAnimatingOvershootOn(false), + mAnimateOvershootOff(false), + mAnchoringEnabled(false), mAnchoringDuration(DEFAULT_ANCHORING_DURATION), mRefreshIntervalLayoutPositions(0.0f), + mRefreshOrderHint(true/*Refresh item 0 first*/), mMinimumSwipeSpeed(DEFAULT_MINIMUM_SWIPE_SPEED), mMinimumSwipeDistance(DEFAULT_MINIMUM_SWIPE_DISTANCE), mWheelScrollDistanceStep(0.0f), mScrollDistance(0.0f), mScrollSpeed(0.0f), + mTotalPanDisplacement(Vector2::ZERO), mScrollOvershoot(0.0f), - mGestureState(Gesture::Clear), - mAnimatingOvershootOn(false), - mAnimateOvershootOff(false), - mAnchoringEnabled(false), - mRefreshOrderHint(true/*Refresh item 0 first*/), mIsFlicking(false), + mGestureState(Gesture::Clear), mAddingItems(false), mRefreshEnabled(true), - mInAnimation(false) + mItemsParentOrigin( ParentOrigin::CENTER), + mItemsAnchorPoint( AnchorPoint::CENTER) { } @@ -317,6 +307,8 @@ void ItemView::OnInitialize() { Actor self = Self(); + SetOvershootEnabled(true); + Vector2 stageSize = Stage::GetCurrent().GetSize(); mWheelScrollDistanceStep = stageSize.y * DEFAULT_WHEEL_SCROLL_DISTANCE_STEP_PROPORTION; @@ -1181,39 +1173,13 @@ void ItemView::OnPan( const PanGesture& gesture ) self.SetProperty(Toolkit::ItemView::Property::LAYOUT_POSITION, firstItemScrollPosition ); - if( ( firstItemScrollPosition >= 0.0f && - currentOvershoot < 1.0f ) || - ( firstItemScrollPosition <= mActiveLayout->GetMinimumLayoutPosition(mItemFactory.GetNumberOfItems(), layoutSize) && - currentOvershoot > -1.0f ) ) + if( (firstItemScrollPosition >= 0.0f && currentOvershoot < 1.0f) || (firstItemScrollPosition >= mActiveLayout->GetMinimumLayoutPosition(mItemFactory.GetNumberOfItems(), layoutSize) && currentOvershoot > -1.0f) ) { mTotalPanDisplacement += gesture.displacement; } mScrollOvershoot = CalculateScrollOvershoot(); - - // If the view is moved in a direction against the overshoot indicator, then the indicator should be animated off. - // First make sure we are not in an animation, otherwise a previously started - // off-animation will be overwritten as the user continues scrolling. - if( !mInAnimation ) - { - // Check if the movement is against the current overshoot amount (if we are currently displaying the indicator). - if( ( ( mScrollOvershoot > Math::MACHINE_EPSILON_0 ) && ( mScrollDistance < -Math::MACHINE_EPSILON_0 ) ) || - ( ( mScrollOvershoot < Math::MACHINE_EPSILON_0 ) && ( mScrollDistance > Math::MACHINE_EPSILON_0 ) ) ) - { - // The user has moved against the indicator direction. - // First, we reset the total displacement. This means the overshoot amount will become zero the next frame, - // and if the user starts dragging in the overshoot direction again, the indicator will appear once more. - mTotalPanDisplacement = Vector2::ZERO; - // Animate the overshoot indicator off. - AnimateScrollOvershoot( 0.0f, false ); - } - else - { - // Only set the property directly if we are not animating the overshoot away, - // as otherwise this will overwrite the animation generated value. - self.SetProperty( Toolkit::ItemView::Property::OVERSHOOT, mScrollOvershoot ); - } - } + self.SetProperty( Toolkit::ItemView::Property::OVERSHOOT, mScrollOvershoot ); } break; @@ -1344,7 +1310,6 @@ void ItemView::OnOvershootOnFinished(Animation& animation) { AnimateScrollOvershoot(0.0f); } - mInAnimation = false; } void ItemView::ScrollToItem(unsigned int itemId, float durationSeconds) @@ -1499,45 +1464,42 @@ void ItemView::EnableScrollOvershoot( bool enable ) Actor self = Self(); if( enable ) { - if( !mOvershootOverlay ) - { - Property::Index effectOvershootPropertyIndex = Property::INVALID_INDEX; - mOvershootOverlay = CreateBouncingEffectActor( effectOvershootPropertyIndex ); - mOvershootOverlay.SetColor(mOvershootEffectColor); - mOvershootOverlay.SetParentOrigin(ParentOrigin::TOP_LEFT); - mOvershootOverlay.SetAnchorPoint(AnchorPoint::TOP_LEFT); - mOvershootOverlay.SetDrawMode( DrawMode::OVERLAY_2D ); - self.Add(mOvershootOverlay); - - Constraint constraint = Constraint::New( mOvershootOverlay, Actor::Property::SIZE, OvershootOverlaySizeConstraint(mOvershootSize.height) ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::SCROLL_DIRECTION ) ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::LAYOUT_ORIENTATION ) ); - constraint.AddSource( ParentSource( Actor::Property::SIZE ) ); - constraint.Apply(); - - mOvershootOverlay.SetSize(mOvershootSize.width, mOvershootSize.height); - - constraint = Constraint::New( mOvershootOverlay, Actor::Property::ORIENTATION, OvershootOverlayRotationConstraint ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::SCROLL_DIRECTION ) ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::LAYOUT_ORIENTATION ) ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::OVERSHOOT ) ); - constraint.Apply(); - - constraint = Constraint::New( mOvershootOverlay, Actor::Property::POSITION, OvershootOverlayPositionConstraint ); - constraint.AddSource( ParentSource( Actor::Property::SIZE ) ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::SCROLL_DIRECTION ) ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::LAYOUT_ORIENTATION ) ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::OVERSHOOT ) ); - constraint.Apply(); - - constraint = Constraint::New( mOvershootOverlay, Actor::Property::VISIBLE, OvershootOverlayVisibilityConstraint ); - constraint.AddSource( ParentSource( Toolkit::Scrollable::Property::CAN_SCROLL_VERTICAL ) ); - constraint.Apply(); - - constraint = Constraint::New( mOvershootOverlay, effectOvershootPropertyIndex, EqualToConstraint() ); - constraint.AddSource( ParentSource( Toolkit::ItemView::Property::OVERSHOOT ) ); - constraint.Apply(); - } + Property::Index effectOvershootPropertyIndex = Property::INVALID_INDEX; + mOvershootOverlay = CreateBouncingEffectActor( effectOvershootPropertyIndex ); + mOvershootOverlay.SetColor(mOvershootEffectColor); + mOvershootOverlay.SetParentOrigin(ParentOrigin::TOP_LEFT); + mOvershootOverlay.SetAnchorPoint(AnchorPoint::TOP_LEFT); + mOvershootOverlay.SetDrawMode( DrawMode::OVERLAY_2D ); + self.Add(mOvershootOverlay); + + Constraint constraint = Constraint::New( mOvershootOverlay, Actor::Property::SIZE, OvershootOverlaySizeConstraint ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::SCROLL_DIRECTION ) ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::LAYOUT_ORIENTATION ) ); + constraint.AddSource( ParentSource( Actor::Property::SIZE ) ); + constraint.Apply(); + + mOvershootOverlay.SetSize(OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.width, OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.height); + + constraint = Constraint::New( mOvershootOverlay, Actor::Property::ORIENTATION, OvershootOverlayRotationConstraint ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::SCROLL_DIRECTION ) ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::LAYOUT_ORIENTATION ) ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::OVERSHOOT ) ); + constraint.Apply(); + + constraint = Constraint::New( mOvershootOverlay, Actor::Property::POSITION, OvershootOverlayPositionConstraint ); + constraint.AddSource( ParentSource( Actor::Property::SIZE ) ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::SCROLL_DIRECTION ) ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::LAYOUT_ORIENTATION ) ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::OVERSHOOT ) ); + constraint.Apply(); + + constraint = Constraint::New( mOvershootOverlay, Actor::Property::VISIBLE, OvershootOverlayVisibilityConstraint ); + constraint.AddSource( ParentSource( Toolkit::Scrollable::Property::CAN_SCROLL_VERTICAL ) ); + constraint.Apply(); + + constraint = Constraint::New( mOvershootOverlay, effectOvershootPropertyIndex, EqualToConstraint() ); + constraint.AddSource( ParentSource( Toolkit::ItemView::Property::OVERSHOOT ) ); + constraint.Apply(); } else { @@ -1598,14 +1560,13 @@ void ItemView::AnimateScrollOvershoot(float overshootAmount, bool animateBack) duration = mOvershootOverlay.GetCurrentSize().height * (animatingOn ? (1.0f - fabsf(currentOvershoot)) : fabsf(currentOvershoot)) / mOvershootAnimationSpeed; } - // Mark the animation as in progress to prevent manual property sets overwriting it. - mInAnimation = true; - mAnimatingOvershootOn = animatingOn; RemoveAnimation(mScrollOvershootAnimation); mScrollOvershootAnimation = Animation::New(duration); mScrollOvershootAnimation.FinishedSignal().Connect(this, &ItemView::OnOvershootOnFinished); mScrollOvershootAnimation.AnimateTo( Property(self, Toolkit::ItemView::Property::OVERSHOOT), overshootAmount, TimePeriod(0.0f, duration) ); mScrollOvershootAnimation.Play(); + + mAnimatingOvershootOn = animatingOn; } else { diff --git a/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.h b/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.h index 2fe5e09..9fc58aa 100644 --- a/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.h +++ b/dali-toolkit/internal/controls/scrollable/item-view/item-view-impl.h @@ -561,44 +561,58 @@ private: private: + ItemFactory& mItemFactory; + typedef std::map ItemPool; typedef ItemPool::iterator ItemPoolIter; typedef ItemPool::const_iterator ConstItemPoolIter; ItemPool mItemPool; - ItemFactory& mItemFactory; - std::vector< ItemLayoutPtr > mLayouts; ///< Container of Dali::Toolkit::ItemLayout objects - Actor mOvershootOverlay; ///< The overlay actor for overshoot effect + + std::vector< ItemLayoutPtr > mLayouts; ///< Container of Dali::Toolkit::ItemLayout objects + ItemLayout* mActiveLayout; + Vector3 mActiveLayoutTargetSize; + Animation mResizeAnimation; Animation mScrollAnimation; Animation mScrollOvershootAnimation; - Timer mWheelEventFinishedTimer; ///< The timer to determine whether there is no wheel event received for a certain period of time. - PropertyNotification mRefreshNotification; ///< Stores the property notification used for item view refresh - LayoutActivatedSignalType mLayoutActivatedSignal; - Vector3 mActiveLayoutTargetSize; - Vector3 mItemsParentOrigin; - Vector3 mItemsAnchorPoint; - Vector2 mTotalPanDisplacement; - ItemLayout* mActiveLayout; + bool mAnimatingOvershootOn; ///< whether we are currently animating overshoot to 1.0f/-1.0f (on) or to 0.0f (off) + bool mAnimateOvershootOff; ///< whether we are currently animating overshoot to 1.0f/-1.0f (on) or to 0.0f (off) + bool mAnchoringEnabled; float mAnchoringDuration; - float mRefreshIntervalLayoutPositions; ///< Refresh item view when the layout position changes by this interval in both positive and negative directions. + + float mRefreshIntervalLayoutPositions; ///< Refresh item view when the layout position changes by this interval in both positive and negative directions. + PropertyNotification mRefreshNotification; // stores the property notification used for item view refresh + bool mRefreshOrderHint; ///< True if scrolling towards the last item + + // Input handling + float mMinimumSwipeSpeed; float mMinimumSwipeDistance; - float mWheelScrollDistanceStep; ///< The step of scroll distance in actor coordinates for each wheel event received. + float mWheelScrollDistanceStep; ///< The step of scroll distance in actor coordinates for each wheel event received. + float mScrollDistance; float mScrollSpeed; + Vector2 mTotalPanDisplacement; + float mScrollOvershoot; + bool mIsFlicking; + + Timer mWheelEventFinishedTimer; ///< The timer to determine whether there is no wheel event received for a certain period of time. + + Dali::Gesture::State mGestureState; - Dali::Gesture::State mGestureState : 3; - bool mAnimatingOvershootOn : 1; ///< Whether we are currently animating overshoot to 1.0f/-1.0f (on) or to 0.0f (off) - bool mAnimateOvershootOff : 1; ///< Whether we are currently animating overshoot to 1.0f/-1.0f (on) or to 0.0f (off) - bool mAnchoringEnabled : 1; - bool mRefreshOrderHint : 1; ///< True if scrolling towards the last item - bool mIsFlicking : 1; - bool mAddingItems : 1; - bool mRefreshEnabled : 1; ///< Whether to refresh the cache automatically - bool mInAnimation : 1; ///< Keeps track of whether an animation is controlling the overshoot property. + Actor mOvershootOverlay; ///< The overlay actor for overshoot effect + + bool mAddingItems; + + bool mRefreshEnabled; ///< Whether to refresh the cache automatically + + Vector3 mItemsParentOrigin; + Vector3 mItemsAnchorPoint; + + LayoutActivatedSignalType mLayoutActivatedSignal; }; } // namespace Internal diff --git a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.cpp b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.cpp index eff1b08..0420830 100644 --- a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.cpp +++ b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.cpp @@ -27,13 +27,13 @@ using namespace Dali; namespace { - +const Vector2 OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE( 720.0f, 42.0f ); const float OVERSHOOT_BOUNCE_ACTOR_RESIZE_THRESHOLD = 180.0f; // local helper function to resize the height of the bounce actor -float GetBounceActorHeight( float width, float defaultHeight ) +float GetBounceActorHeight( float width ) { - return (width > OVERSHOOT_BOUNCE_ACTOR_RESIZE_THRESHOLD) ? defaultHeight : defaultHeight * 0.5f; + return (width > OVERSHOOT_BOUNCE_ACTOR_RESIZE_THRESHOLD) ? OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.height : OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.height * 0.5f; } const float MAX_OVERSHOOT_NOTIFY_AMOUNT = 0.99f; // maximum amount to set notification for increased overshoot, beyond this we just wait for it to reduce again @@ -129,7 +129,6 @@ ScrollOvershootEffectRipple::ScrollOvershootEffectRipple( bool vertical, Scrolla mOvershootProperty(Property::INVALID_INDEX), mEffectOvershootProperty(Property::INVALID_INDEX), mOvershoot(0.0f), - mOvershootSize( scrollable.GetOvershootSize() ), mAnimationStateFlags(0) { mOvershootOverlay = CreateBouncingEffectActor(mEffectOvershootProperty); @@ -146,8 +145,7 @@ void ScrollOvershootEffectRipple::Apply() mOvershootProperty = IsVertical() ? Toolkit::ScrollView::Property::OVERSHOOT_Y : Toolkit::ScrollView::Property::OVERSHOOT_X; // make sure height is set, since we only create a constraint for image width - mOvershootSize = mAttachedScrollView.GetOvershootSize(); - mOvershootOverlay.SetSize( mOvershootSize ); + mOvershootOverlay.SetSize(OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.width, OVERSHOOT_BOUNCE_ACTOR_DEFAULT_SIZE.height); mAttachedScrollView.AddOverlay(mOvershootOverlay); @@ -244,12 +242,12 @@ void ScrollOvershootEffectRipple::UpdateVisibility( bool visible ) if(IsVertical()) { mOvershootOverlay.SetOrientation( Quaternion( Radian( 0.0f ), Vector3::ZAXIS ) ); - mOvershootOverlay.SetSize(parentSize.width, GetBounceActorHeight(parentSize.width, mOvershootSize.height), size.depth); + mOvershootOverlay.SetSize(parentSize.width, GetBounceActorHeight(parentSize.width), size.depth); } else { mOvershootOverlay.SetOrientation( Quaternion( Radian( 1.5f * Math::PI ), Vector3::ZAXIS ) ); - mOvershootOverlay.SetSize(parentSize.height, GetBounceActorHeight(parentSize.height, mOvershootSize.height), size.depth); + mOvershootOverlay.SetSize(parentSize.height, GetBounceActorHeight(parentSize.height), size.depth); relativeOffset = Vector3(0.0f, 1.0f, 0.0f); } mOvershootOverlay.SetPosition(relativeOffset * parentSize); @@ -263,13 +261,13 @@ void ScrollOvershootEffectRipple::UpdateVisibility( bool visible ) if(IsVertical()) { mOvershootOverlay.SetOrientation( Quaternion( Radian( Math::PI ), Vector3::ZAXIS ) ); - mOvershootOverlay.SetSize(parentSize.width, GetBounceActorHeight(parentSize.width, mOvershootSize.height), size.depth); + mOvershootOverlay.SetSize(parentSize.width, GetBounceActorHeight(parentSize.width), size.depth); relativeOffset = Vector3(1.0f, 1.0f, 0.0f); } else { mOvershootOverlay.SetOrientation( Quaternion( Radian( 0.5f * Math::PI ), Vector3::ZAXIS ) ); - mOvershootOverlay.SetSize(parentSize.height, GetBounceActorHeight(parentSize.height, mOvershootSize.height), size.depth); + mOvershootOverlay.SetSize(parentSize.height, GetBounceActorHeight(parentSize.height), size.depth); relativeOffset = Vector3(1.0f, 0.0f, 0.0f); } mOvershootOverlay.SetPosition(relativeOffset * parentSize); diff --git a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.h b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.h index 1dadcfc..7eebe4b 100644 --- a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.h +++ b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-overshoot-indicator-impl.h @@ -251,9 +251,8 @@ private: PropertyNotification mOvershootDecreaseNotification;///< notification used to inform as overshoot decreases Property::Index mOvershootProperty; ///< index of the overshoot property in the scrollable actor Property::Index mEffectOvershootProperty; ///< index of the effect's overshoot property - float mOvershoot; ///< last overshoot value as detected by notifications - Vector2 mOvershootSize; ///< The size of the overshoot effect - unsigned short mAnimationStateFlags; ///< contains flags indicating the current state of the overshoot animation + float mOvershoot; ///< last overshoot value as detected by notifications + unsigned short mAnimationStateFlags; ///< contains flags indicating the current state of the overshoot animation }; } // namespace Internal diff --git a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp index c07f6ff..1ca9ee8 100644 --- a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp +++ b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp @@ -29,6 +29,7 @@ #include // INTERNAL INCLUDES +#include #include #include #include @@ -312,132 +313,93 @@ ScrollView::LockAxis GetLockAxis(const Vector2& panDelta, ScrollView::LockAxis c */ struct InternalPrePositionConstraint { - InternalPrePositionConstraint( const Vector2& initialPanPosition, - const Vector2& initialPanMask, - bool axisAutoLock, - float axisAutoLockGradient, - ScrollView::LockAxis initialLockAxis, - const Vector2& maxOvershoot, - const RulerPtr& rulerX, const RulerPtr& rulerY ) - : mLocalStart( initialPanPosition ), - mInitialPanMask( initialPanMask ), - mMaxOvershoot( maxOvershoot ), - mAxisAutoLockGradient( axisAutoLockGradient ), - mLockAxis( initialLockAxis ), - mAxisAutoLock( axisAutoLock ), - mWasPanning( false ) - { - const RulerDomain& rulerDomainX = rulerX->GetDomain(); - const RulerDomain& rulerDomainY = rulerY->GetDomain(); - mDomainMin = Vector2( rulerDomainX.min, -rulerDomainY.min ); - mDomainMax = Vector2( -rulerDomainX.max, -rulerDomainY.max ); - mClampX = rulerDomainX.enabled; - mClampY = rulerDomainY.enabled; - mFixedRulerX = rulerX->GetType() == Ruler::Fixed; - mFixedRulerY = rulerY->GetType() == Ruler::Fixed; + InternalPrePositionConstraint(const Vector2& initialPanPosition, + const Vector2& initialPanMask, + bool axisAutoLock, + float axisAutoLockGradient, + ScrollView::LockAxis initialLockAxis, + const Vector2& maxOvershoot, + const RulerDomain& domainX, const RulerDomain& domainY) + : mLocalStart(initialPanPosition), + mInitialPanMask(initialPanMask), + mDomainMin( -domainX.min, -domainY.min ), + mDomainMax( -domainX.max, -domainY.max ), + mMaxOvershoot(maxOvershoot), + mAxisAutoLockGradient(axisAutoLockGradient), + mLockAxis(initialLockAxis), + mAxisAutoLock(axisAutoLock), + mWasPanning(false), + mClampX( domainX.enabled ), + mClampY( domainY.enabled ) + { } void operator()( Vector2& scrollPostPosition, const PropertyInputContainer& inputs ) { const Vector2& panPosition = inputs[0]->GetVector2(); - const bool& inGesture = inputs[1]->GetBoolean(); - // First check if we are within a gesture. - // The ScrollView may have received a start gesture from ::OnPan() - // while the finish gesture is received now in this constraint. - // This gesture must then be rejected as the value will be "old". - // Typically the last value from the end of the last gesture. - // If we are rejecting the gesture, we simply don't modify the constraint target. - if( inGesture ) + if(!mWasPanning) { - if( !mWasPanning ) - { - mPrePosition = scrollPostPosition; - mStartPosition = mPrePosition; - mCurrentPanMask = mInitialPanMask; - mWasPanning = true; - } + mPrePosition = scrollPostPosition; + mCurrentPanMask = mInitialPanMask; + mWasPanning = true; + } - // Calculate Deltas... - const Vector2& currentPosition = panPosition; - Vector2 panDelta( currentPosition - mLocalStart ); + // Calculate Deltas... + const Vector2& currentPosition = panPosition; + Vector2 panDelta( currentPosition - mLocalStart ); - // Axis Auto Lock - locks the panning to the horizontal or vertical axis if the pan - // appears mostly horizontal or mostly vertical respectively... - if( mAxisAutoLock ) + // Axis Auto Lock - locks the panning to the horizontal or vertical axis if the pan + // appears mostly horizontal or mostly vertical respectively... + if( mAxisAutoLock ) + { + mLockAxis = GetLockAxis(panDelta, mLockAxis, mAxisAutoLockGradient); + if( mLockAxis == ScrollView::LockVertical ) { - mLockAxis = GetLockAxis( panDelta, mLockAxis, mAxisAutoLockGradient ); - if( mLockAxis == ScrollView::LockVertical ) - { - mCurrentPanMask.y = 0.0f; - } - else if( mLockAxis == ScrollView::LockHorizontal ) - { - mCurrentPanMask.x = 0.0f; - } + mCurrentPanMask.y = 0.0f; + } + else if( mLockAxis == ScrollView::LockHorizontal ) + { + mCurrentPanMask.x = 0.0f; } + } - // Restrict deltas based on ruler enable/disable and axis-lock state... - panDelta *= mCurrentPanMask; + // Restrict deltas based on ruler enable/disable and axis-lock state... + panDelta *= mCurrentPanMask; - // Perform Position transform based on input deltas... - scrollPostPosition = mPrePosition; - scrollPostPosition += panDelta; + // Perform Position transform based on input deltas... + scrollPostPosition = mPrePosition; + scrollPostPosition += panDelta; - // if no wrapping then clamp preposition to maximum overshoot amount - const Vector3& size = inputs[2]->GetVector3(); - if( mClampX ) + // if no wrapping then clamp preposition to maximum overshoot amount + const Vector3& size = inputs[1]->GetVector3(); + if( mClampX ) + { + float newXPosition = Clamp(scrollPostPosition.x, (mDomainMax.x + size.x) - mMaxOvershoot.x, mDomainMin.x + mMaxOvershoot.x ); + if( (newXPosition < scrollPostPosition.x - Math::MACHINE_EPSILON_1) + || (newXPosition > scrollPostPosition.x + Math::MACHINE_EPSILON_1) ) { - float newXPosition = Clamp( scrollPostPosition.x, ( mDomainMax.x + size.x ) - mMaxOvershoot.x, mDomainMin.x + mMaxOvershoot.x ); - if( (newXPosition < scrollPostPosition.x - Math::MACHINE_EPSILON_1) - || (newXPosition > scrollPostPosition.x + Math::MACHINE_EPSILON_1) ) - { - mPrePosition.x = newXPosition; - mLocalStart.x = panPosition.x; - } - scrollPostPosition.x = newXPosition; + mPrePosition.x = newXPosition; + mLocalStart.x = panPosition.x; } - if( mClampY ) + scrollPostPosition.x = newXPosition; + } + if( mClampY ) + { + float newYPosition = Clamp(scrollPostPosition.y, (mDomainMax.y + size.y) - mMaxOvershoot.y, mDomainMin.y + mMaxOvershoot.y ); + if( (newYPosition < scrollPostPosition.y - Math::MACHINE_EPSILON_1) + || (newYPosition > scrollPostPosition.y + Math::MACHINE_EPSILON_1) ) { - float newYPosition = Clamp( scrollPostPosition.y, ( mDomainMax.y + size.y ) - mMaxOvershoot.y, mDomainMin.y + mMaxOvershoot.y ); - if( ( newYPosition < scrollPostPosition.y - Math::MACHINE_EPSILON_1 ) - || ( newYPosition > scrollPostPosition.y + Math::MACHINE_EPSILON_1 ) ) - { - mPrePosition.y = newYPosition; - mLocalStart.y = panPosition.y; - } - scrollPostPosition.y = newYPosition; - } - - // If we are using a fixed ruler in a particular axis, limit the maximum pages scrolled on that axis. - if( mFixedRulerX || mFixedRulerY ) - { - // Here we limit the maximum amount that can be moved from the starting position of the gesture to one page. - // We do this only if we have a fixed ruler (on that axis) and the mode is enabled. - // Note: 1.0f is subtracted to keep the value within one page size (otherwise we stray on to the page after). - // Note: A further 1.0f is subtracted to handle a compensation that happens later within the flick handling code in SnapWithVelocity(). - // When a flick is completed, an adjustment of 1.0f is sometimes made to allow for the scenario where: - // A flick finishes before the update thread has advanced the scroll position past the previous snap point. - Vector2 pageSizeLimit( size.x - ( 1.0f + 1.0f ), size.y - ( 1.0f - 1.0f ) ); - Vector2 minPosition( mStartPosition.x - pageSizeLimit.x, mStartPosition.y - pageSizeLimit.y ); - Vector2 maxPosition( mStartPosition.x + pageSizeLimit.x, mStartPosition.y + pageSizeLimit.y ); - - if( mFixedRulerX ) - { - scrollPostPosition.x = Clamp( scrollPostPosition.x, minPosition.x, maxPosition.x ); - } - if( mFixedRulerY ) - { - scrollPostPosition.y = Clamp( scrollPostPosition.y, minPosition.y, maxPosition.y ); - } + mPrePosition.y = newYPosition; + mLocalStart.y = panPosition.y; } + scrollPostPosition.y = newYPosition; } } Vector2 mPrePosition; Vector2 mLocalStart; - Vector2 mStartPosition; ///< The start position of the gesture - used to limit scroll amount (not modified by clamping). - Vector2 mInitialPanMask; ///< Initial pan mask (based on ruler settings). + Vector2 mInitialPanMask; ///< Initial pan mask (based on ruler settings) Vector2 mCurrentPanMask; ///< Current pan mask that can be altered by axis lock mode. Vector2 mDomainMin; Vector2 mDomainMax; @@ -446,12 +408,10 @@ struct InternalPrePositionConstraint float mAxisAutoLockGradient; ///< Set by ScrollView ScrollView::LockAxis mLockAxis; - bool mAxisAutoLock:1; ///< Set by ScrollView + bool mAxisAutoLock:1; ///< Set by ScrollView bool mWasPanning:1; bool mClampX:1; bool mClampY:1; - bool mFixedRulerX:1; - bool mFixedRulerY:1; }; /** @@ -640,6 +600,7 @@ ScrollView::ScrollView() mMaxFlickSpeed(DEFAULT_MAX_FLICK_SPEED), mWheelScrollDistanceStep(Vector2::ZERO), mInAccessibilityPan(false), + mInitialized(false), mScrolling(false), mScrollInterrupted(false), mPanning(false), @@ -675,6 +636,8 @@ void ScrollView::OnInitialize() mWheelScrollDistanceStep = Stage::GetCurrent().GetSize() * DEFAULT_WHEEL_SCROLL_DISTANCE_STEP_PROPORTION; + mInitialized = true; + mGestureStackDepth = 0; EnableGestureDetection( Gesture::Type( Gesture::Pan ) ); @@ -685,6 +648,8 @@ void ScrollView::OnInitialize() mRulerX = ruler; mRulerY = ruler; + SetOvershootEnabled(true); + self.SetProperty(Toolkit::Scrollable::Property::CAN_SCROLL_VERTICAL, mCanScrollVertical); self.SetProperty(Toolkit::Scrollable::Property::CAN_SCROLL_HORIZONTAL, mCanScrollHorizontal); @@ -1733,25 +1698,19 @@ bool ScrollView::AnimateTo(const Vector2& position, const Vector2& positionDurat void ScrollView::EnableScrollOvershoot(bool enable) { - if (enable) + if(enable && !mOvershootIndicator) + { + mOvershootIndicator = ScrollOvershootIndicator::New(); + } + if( enable ) { - if (!mOvershootIndicator) - { - mOvershootIndicator = ScrollOvershootIndicator::New(); - } - mOvershootIndicator->AttachToScrollable(*this); } else { mMaxOvershoot = mUserMaxOvershoot; - - if (mOvershootIndicator) - { - mOvershootIndicator->DetachFromScrollable(*this); - } + mOvershootIndicator->DetachFromScrollable(*this); } - UpdateMainInternalConstraint(); } @@ -1932,35 +1891,29 @@ void ScrollView::OnSizeSet( const Vector3& size ) void ScrollView::OnChildAdd(Actor& child) { Dali::Toolkit::ScrollBar scrollBar = Dali::Toolkit::ScrollBar::DownCast(child); - if( scrollBar ) + if(scrollBar) { - mScrollBar = scrollBar; - mScrollBar.SetName("ScrollBar"); - - mInternalActor.Add( mScrollBar ); - if( mScrollBar.GetScrollDirection() == Toolkit::ScrollBar::Horizontal ) + mInternalActor.Add(scrollBar); + if(scrollBar.GetScrollDirection() == Toolkit::ScrollBar::Horizontal) { - mScrollBar.SetScrollPropertySource( Self(), - Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_X, - Toolkit::Scrollable::Property::SCROLL_POSITION_MIN_X, - Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_MAX_X, - Toolkit::ScrollView::Property::SCROLL_DOMAIN_SIZE_X ); + scrollBar.SetScrollPropertySource(Self(), + Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_X, + Toolkit::Scrollable::Property::SCROLL_POSITION_MIN_X, + Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_MAX_X, + Toolkit::ScrollView::Property::SCROLL_DOMAIN_SIZE_X); } else { - mScrollBar.SetScrollPropertySource( Self(), - Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_Y, - Toolkit::Scrollable::Property::SCROLL_POSITION_MIN_Y, - Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_MAX_Y, - Toolkit::ScrollView::Property::SCROLL_DOMAIN_SIZE_Y ); + scrollBar.SetScrollPropertySource(Self(), + Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_Y, + Toolkit::Scrollable::Property::SCROLL_POSITION_MIN_Y, + Toolkit::ScrollView::Property::SCROLL_PRE_POSITION_MAX_Y, + Toolkit::ScrollView::Property::SCROLL_DOMAIN_SIZE_Y); } - - mScrollBar.SetVisible( false ); - mScrollBar.HideIndicator(); } - else if( mAlterChild ) + else if(mAlterChild) { - BindActor( child ); + BindActor(child); } } @@ -2453,18 +2406,6 @@ void ScrollView::OnPan( const PanGesture& gesture ) self.SetProperty( Toolkit::ScrollView::Property::START_PAGE_POSITION, Vector3(gesture.position.x, gesture.position.y, 0.0f) ); UpdateMainInternalConstraint(); - if( mScrollBar ) - { - Vector3 size = Self().GetCurrentSize(); - const Toolkit::RulerDomain& rulerDomainX = mRulerX->GetDomain(); - const Toolkit::RulerDomain& rulerDomainY = mRulerY->GetDomain(); - - if( ( rulerDomainX.max > size.width ) || ( rulerDomainY.max > size.height ) ) - { - mScrollBar.SetVisible( true ); - mScrollBar.ShowIndicator(); - } - } break; } @@ -2499,11 +2440,6 @@ void ScrollView::OnPan( const PanGesture& gesture ) { mScrollMainInternalPrePositionConstraint.Remove(); } - - if( mScrollBar ) - { - mScrollBar.HideIndicator(); - } } else { @@ -2722,10 +2658,9 @@ void ScrollView::UpdateMainInternalConstraint() mAxisAutoLockGradient, mLockAxis, mMaxOvershoot, - mRulerX, - mRulerY ) ); + mRulerX->GetDomain(), + mRulerY->GetDomain() ) ); mScrollMainInternalPrePositionConstraint.AddSource( Source( detector, PanGestureDetector::Property::LOCAL_POSITION ) ); - mScrollMainInternalPrePositionConstraint.AddSource( Source( detector, PanGestureDetector::Property::PANNING ) ); mScrollMainInternalPrePositionConstraint.AddSource( Source( self, Actor::Property::SIZE ) ); mScrollMainInternalPrePositionConstraint.Apply(); } diff --git a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.h b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.h index 49ff741..bbd87bc 100644 --- a/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.h +++ b/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.h @@ -25,10 +25,9 @@ // INTERNAL INCLUDES #include -#include +#include #include #include -#include namespace Dali { @@ -898,11 +897,11 @@ private: Constraint mScrollMainInternalPrePositionMaxConstraint; ScrollOvershootIndicatorPtr mOvershootIndicator; - Toolkit::ScrollBar mScrollBar; Toolkit::ScrollView::SnapStartedSignalType mSnapStartedSignal; - bool mInAccessibilityPan:1; ///< With AccessibilityPan its easier to move between snap positions + bool mInAccessibilityPan : 1; ///< With AccessibilityPan its easier to move between snap positions + bool mInitialized:1; bool mScrolling:1; ///< Flag indicating whether the scroll view is being scrolled (by user or animation) bool mScrollInterrupted:1; ///< Flag set for when a down event interrupts a scroll bool mPanning:1; ///< Whether scroll view is currently panning or not diff --git a/dali-toolkit/internal/controls/scrollable/scrollable-impl.cpp b/dali-toolkit/internal/controls/scrollable/scrollable-impl.cpp index 977d991..b3a2152 100644 --- a/dali-toolkit/internal/controls/scrollable/scrollable-impl.cpp +++ b/dali-toolkit/internal/controls/scrollable/scrollable-impl.cpp @@ -48,8 +48,6 @@ DALI_TYPE_REGISTRATION_BEGIN( Toolkit::Scrollable, Toolkit::Control, Create ); DALI_PROPERTY_REGISTRATION( Toolkit, Scrollable, "overshoot-effect-color", VECTOR4, OVERSHOOT_EFFECT_COLOR ) DALI_PROPERTY_REGISTRATION( Toolkit, Scrollable, "overshoot-animation-speed", FLOAT, OVERSHOOT_ANIMATION_SPEED ) -const int OVERSHOOT_SIZE = Dali::Toolkit::Scrollable::Property::OVERSHOOT_ANIMATION_SPEED + 1; // OVERSHOOT_SIZE is not public yet -Dali::PropertyRegistration p1( typeRegistration, "overshoot-size", OVERSHOOT_SIZE, Property::VECTOR2, Dali::Toolkit::Internal::Scrollable::SetProperty, Dali::Toolkit::Internal::Scrollable::GetProperty ); DALI_ANIMATABLE_PROPERTY_REGISTRATION( Toolkit, Scrollable, "scroll-relative-position", VECTOR2, SCROLL_RELATIVE_POSITION) DALI_ANIMATABLE_PROPERTY_REGISTRATION( Toolkit, Scrollable, "scroll-position-min", VECTOR2, SCROLL_POSITION_MIN) @@ -69,7 +67,6 @@ DALI_TYPE_REGISTRATION_END() const Vector4 DEFAULT_OVERSHOOT_COLOUR(0.0f, 0.64f, 0.85f, 0.25f); const float DEFAULT_OVERSHOOT_ANIMATION_SPEED(120.0f); // 120 pixels per second -const Vector2 OVERSHOOT_DEFAULT_SIZE( 720.0f, 42.0f ); } @@ -83,8 +80,7 @@ Scrollable::Scrollable() : Control( ControlBehaviour( REQUIRES_TOUCH_EVENTS | REQUIRES_STYLE_CHANGE_SIGNALS | DISABLE_SIZE_NEGOTIATION ) ), mOvershootEffectColor( DEFAULT_OVERSHOOT_COLOUR ), mOvershootAnimationSpeed ( DEFAULT_OVERSHOOT_ANIMATION_SPEED ), - mOvershootSize( OVERSHOOT_DEFAULT_SIZE ), - mOvershootEnabled(true) + mOvershootEnabled(false) { } @@ -92,8 +88,7 @@ Scrollable::Scrollable( ControlBehaviour behaviourFlags ) : Control( ControlBehaviour( REQUIRES_TOUCH_EVENTS | REQUIRES_STYLE_CHANGE_SIGNALS | behaviourFlags ) ), mOvershootEffectColor( DEFAULT_OVERSHOOT_COLOUR ), mOvershootAnimationSpeed ( DEFAULT_OVERSHOOT_ANIMATION_SPEED ), - mOvershootSize( OVERSHOOT_DEFAULT_SIZE ), - mOvershootEnabled(true) + mOvershootEnabled(false) { } @@ -189,12 +184,6 @@ void Scrollable::SetProperty( BaseObject* object, Property::Index index, const P scrollableImpl.SetOvershootAnimationSpeed( value.Get() ); break; } - case OVERSHOOT_SIZE: // OVERSHOOT_SIZE is not public yet - { - scrollableImpl.mOvershootSize = value.Get(); - scrollableImpl.EnableScrollOvershoot(scrollableImpl.IsOvershootEnabled()); - break; - } } } } @@ -220,11 +209,6 @@ Property::Value Scrollable::GetProperty( BaseObject* object, Property::Index ind value = scrollableImpl.GetOvershootAnimationSpeed(); break; } - case OVERSHOOT_SIZE: // OVERSHOOT_SIZE is not public yet - { - value = scrollableImpl.mOvershootSize; - break; - } } } diff --git a/dali-toolkit/internal/controls/scrollable/scrollable-impl.h b/dali-toolkit/internal/controls/scrollable/scrollable-impl.h index 06a4269..0b349f5 100644 --- a/dali-toolkit/internal/controls/scrollable/scrollable-impl.h +++ b/dali-toolkit/internal/controls/scrollable/scrollable-impl.h @@ -110,11 +110,6 @@ public: */ float GetOvershootAnimationSpeed() const; - /** - * @copydoc Dali::Toolkit::Scrollable::GetOvershootSize() - */ - const Vector2& GetOvershootSize() { return mOvershootSize; } - private: /** @@ -210,7 +205,6 @@ protected: Vector4 mOvershootEffectColor; ///& removed ) else if( row >= rowIndex ) // If below of or at the inserted row, decrease row index { // Decrement index - if( position.rowIndex > 0 ) + if( position.rowIndex > 1 ) { position.rowIndex--; } diff --git a/dali-toolkit/internal/controls/text-controls/text-field-impl.cpp b/dali-toolkit/internal/controls/text-controls/text-field-impl.cpp index 44714b1..9c3d4c8 100644 --- a/dali-toolkit/internal/controls/text-controls/text-field-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-field-impl.cpp @@ -893,7 +893,7 @@ void TextField::OnInitialize() mController->EnableTextInput( mDecorator ); // Forward input events to controller - EnableGestureDetection( static_cast( Gesture::Tap | Gesture::Pan | Gesture::LongPress ) ); + EnableGestureDetection( static_cast( Gesture::Tap | Gesture::Pan |Gesture::LongPress ) ); GetTapGestureDetector().SetMaximumTapsRequired( 2 ); self.TouchedSignal().Connect( this, &TextField::OnTouched ); @@ -908,9 +908,6 @@ void TextField::OnInitialize() mDecorator->SetBoundingBox( Rect( 0.0f, 0.0f, stageSize.width, stageSize.height ) ); } - // Flip vertically the 'left' selection handle - mDecorator->FlipHandleVertically( LEFT_SELECTION_HANDLE, true ); - // Fill-parent area by default self.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::WIDTH ); self.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::HEIGHT ); @@ -1098,7 +1095,6 @@ void TextField::OnKeyInputFocusLost() notifier.ContentSelectedSignal().Disconnect( this, &TextField::OnClipboardTextSelected ); } - mController->KeyboardFocusGainEvent(); // Called to set the text controller in EDITING status in case it is in INTERRUPTED. Next KeyboardFocusLostEvent() call will set the status to INACTIVE. mController->KeyboardFocusLostEvent(); EmitKeyInputFocusSignal( false ); // Calls back into the Control hence done last. diff --git a/dali-toolkit/internal/controls/text-controls/text-label-impl.cpp b/dali-toolkit/internal/controls/text-controls/text-label-impl.cpp index 7159160..1c31449 100644 --- a/dali-toolkit/internal/controls/text-controls/text-label-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-label-impl.cpp @@ -284,7 +284,7 @@ void TextLabel::SetProperty( BaseObject* object, Property::Index index, const Pr if( impl.mController ) { float height = value.Get< float >(); - if( fabsf( impl.mController->GetUnderlineHeight() - height ) > Math::MACHINE_EPSILON_1000 ) + if ( impl.mController->GetUnderlineHeight() != height ) { impl.mController->SetUnderlineHeight( height ); impl.mRenderer.Reset(); @@ -445,10 +445,7 @@ void TextLabel::OnInitialize() // Enable the text ellipsis. LayoutEngine& engine = mController->GetLayoutEngine(); - engine.SetTextEllipsisEnabled( true ); - engine.SetCursorWidth( 0u ); // Do not layout space for the cursor. - self.OnStageSignal().Connect( this, &TextLabel::OnStageConnect ); } diff --git a/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.cpp b/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.cpp index adb29ed..7e4df4b 100644 --- a/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.cpp @@ -26,8 +26,8 @@ // EXTERNAL INCLUDES #include -#include #include +#include #include #include #include @@ -36,7 +36,6 @@ #include #include -#include namespace Dali { @@ -112,59 +111,9 @@ DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionPopup, "popup-pressed-color", DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionPopup, "popup-pressed-image", STRING, POPUP_PRESSED_IMAGE ) DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionPopup, "popup-fade-in-duration", FLOAT, POPUP_FADE_IN_DURATION ) DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionPopup, "popup-fade-out-duration", FLOAT, POPUP_FADE_OUT_DURATION ) -DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionPopup, "popup-background-image", MAP, POPUP_BACKGROUND_IMAGE ) DALI_TYPE_REGISTRATION_END() -// Popup's background. - -const std::string TEXTURE_UNIFORM_NAME = "sTexture"; - -unsigned int gBackgroundQuadIndex[] = { 0, 4, 1, - 1, 4, 5, - 1, 5, 2, - 2, 5, 6, - 2, 6, 3, - 3, 6, 7, - 4, 8, 5, - 5, 8, 9, - 5, 9, 6, - 6, 9, 10, - 6, 10, 7, - 7, 10, 11, - 8, 12, 9, - 9, 12, 13, - 9, 13, 10, - 10, 13, 14, - 10, 14, 11, - 11, 14, 15 }; - -const char* VERTEX_SHADER_COLOR = DALI_COMPOSE_SHADER( - attribute mediump vec2 aPosition;\n - attribute mediump vec2 aTextCoord;\n - varying mediump vec2 vTexCoord;\n - uniform mediump mat4 uMvpMatrix;\n - \n - void main()\n - {\n - vTexCoord = aTextCoord;\n - gl_Position = uMvpMatrix * vec4( aPosition, 0.0, 1.0 );\n - }\n -); - -const char* FRAGMENT_SHADER_COLOR = DALI_COMPOSE_SHADER( - varying mediump vec2 vTexCoord;\n - uniform sampler2D sTexture;\n - uniform lowp vec4 uBackgroundColor;\n - uniform lowp vec4 uStrokeColor;\n - \n - void main()\n - {\n - lowp vec4 color = texture2D( sTexture, vTexCoord );\n - gl_FragColor = color.r * uStrokeColor + color.b * uBackgroundColor;\n - }\n -); - } // namespace @@ -281,54 +230,6 @@ void TextSelectionPopup::SetProperty( BaseObject* object, Property::Index index, impl.mFadeOutDuration = value.Get < float >(); break; } - case Toolkit::TextSelectionPopup::Property::POPUP_BACKGROUND_IMAGE: - { - const Property::Map* map = value.GetMap(); - - if( map ) - { - // used to retrieve the POPUP_BACKGROUND_IMAGE property. - impl.mBackgroundMap = *map; - - Image backgroundImage; - - std::string filename; - - const Property::Value* value = map->Find( "filename" ); - if( value ) - { - value->Get( filename ); - } - - // if empty file, no need to go further - if( filename.empty() ) - { - DALI_LOG_ERROR( "No filename\n" ); - } - else - { - backgroundImage = ResourceImage::New( filename ); - - Vector4 backgroundColor; - Vector4 strokeColor; - - value = map->Find( "background-color" ); - if( value ) - { - backgroundColor = value->Get(); - } - - value = map->Find( "stroke-color" ); - if( value ) - { - strokeColor = value->Get(); - } - - impl.SetPopupBackgroundImage( backgroundImage, backgroundColor, strokeColor ); - } - } - break; - } } // switch } // TextSelectionPopup } @@ -434,11 +335,6 @@ Property::Value TextSelectionPopup::GetProperty( BaseObject* object, Property::I value = impl.mFadeOutDuration; break; } - case Toolkit::TextSelectionPopup::Property::POPUP_BACKGROUND_IMAGE: - { - value = impl.mBackgroundMap; - break; - } } // switch } return value; @@ -491,8 +387,6 @@ void TextSelectionPopup::OnInitialize() Actor self = Self(); self.SetResizePolicy( ResizePolicy::FIT_TO_CHILDREN, Dimension::ALL_DIMENSIONS ); self.SetProperty( Actor::Property::COLOR_ALPHA, 0.0f ); - - self.OnRelayoutSignal().Connect( this, &TextSelectionPopup::RelayoutComplete ); } void TextSelectionPopup::OnStageConnection( int depth ) @@ -507,7 +401,7 @@ void TextSelectionPopup::OnStageConnection( int depth ) void TextSelectionPopup::HideAnimationFinished( Animation& animation ) { Actor self = Self(); - if( !mPopupShowing ) // During the Hide/Fade animation there could be a call to Show the Popup again, mPopupShowing will be true in this case. + if ( !mPopupShowing ) // During the Hide/Fade animation there could be a call to Show the Popup again, mPopupShowing will be true in this case. { DALI_LOG_INFO( gLogFilter, Debug::General, "TextSelectionPopup::HideAnimationFinished\n" ); UnparentAndReset( mToolbar ); @@ -518,7 +412,6 @@ bool TextSelectionPopup::OnCutButtonPressed( Toolkit::Button button ) { if( mCallbackInterface ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); mCallbackInterface->TextPopupButtonTouched( Toolkit::TextSelectionPopup::CUT ); } @@ -529,7 +422,6 @@ bool TextSelectionPopup::OnCopyButtonPressed( Toolkit::Button button ) { if( mCallbackInterface ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); mCallbackInterface->TextPopupButtonTouched( Dali::Toolkit::TextSelectionPopup::COPY ); } @@ -540,7 +432,6 @@ bool TextSelectionPopup::OnPasteButtonPressed( Toolkit::Button button ) { if( mCallbackInterface ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); mCallbackInterface->TextPopupButtonTouched( Dali::Toolkit::TextSelectionPopup::PASTE ); } @@ -551,7 +442,6 @@ bool TextSelectionPopup::OnSelectButtonPressed( Toolkit::Button button ) { if( mCallbackInterface ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); mCallbackInterface->TextPopupButtonTouched( Dali::Toolkit::TextSelectionPopup::SELECT ); } @@ -562,7 +452,6 @@ bool TextSelectionPopup::OnSelectAllButtonPressed( Toolkit::Button button ) { if( mCallbackInterface ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); mCallbackInterface->TextPopupButtonTouched( Dali::Toolkit::TextSelectionPopup::SELECT_ALL ); } @@ -573,7 +462,6 @@ bool TextSelectionPopup::OnClipboardButtonPressed( Toolkit::Button button ) { if( mCallbackInterface ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); mCallbackInterface->TextPopupButtonTouched( Dali::Toolkit::TextSelectionPopup::CLIPBOARD ); } @@ -882,7 +770,7 @@ std::string TextSelectionPopup::GetPressedImage() const CreateOrderedListOfPopupOptions(); mButtonsChanged = false; - UnparentAndReset( mToolbar ); + UnparentAndReset( mToolbar); if( !mToolbar ) { @@ -913,166 +801,9 @@ std::string TextSelectionPopup::GetPressedImage() const } } -void TextSelectionPopup::SetPopupBackgroundImage( Image image, - const Vector4& backgroundColor, - const Vector4& strokeColor ) -{ - NinePatchImage ninePatch = NinePatchImage::DownCast( image ); - - if( ninePatch ) - { - mNinePatchBorder = static_cast( ninePatch.GetChildRectangle().x ); - mNinePatchBorderPercentage = mNinePatchBorder / static_cast( ninePatch.GetWidth() ); - - if( !mBackgroundVertexBuffer ) - { - Property::Map vertexFormat; - vertexFormat["aPosition"] = Property::VECTOR2; - vertexFormat["aTextCoord"] = Property::VECTOR2; - - //Create a vertex buffer for vertex positions - mBackgroundVertexBuffer = PropertyBuffer::New( vertexFormat, 16u ); - - Vector geometry; - geometry.Resize( 32u ); - mBackgroundVertexBuffer.SetData( geometry.Begin() ); - } - - if( !mBackgroundRenderer ) - { - Image croppedImage = ninePatch.CreateCroppedBufferImage(); - if( croppedImage ) - { - Shader shader = Shader::New( VERTEX_SHADER_COLOR, FRAGMENT_SHADER_COLOR, Shader::HINT_OUTPUT_IS_TRANSPARENT ); - - Material material = Material::New( shader ); - - Sampler sampler = Sampler::New( croppedImage, TEXTURE_UNIFORM_NAME ); - sampler.SetAffectsTransparency( true ); - - material.AddSampler( sampler ); - - //Create the index buffer - Property::Map indexFormat; - indexFormat["indices"] = Property::INTEGER; - PropertyBuffer indexBuffer = PropertyBuffer::New( indexFormat, 54u ); - indexBuffer.SetData( gBackgroundQuadIndex ); - - //Create the geometry - Geometry mesh = Geometry::New(); - mesh.AddVertexBuffer( mBackgroundVertexBuffer ); - mesh.SetIndexBuffer( indexBuffer ); - - //Add uniforms to the shader - mBackgroundColorIndex = shader.RegisterProperty( "uBackgroundColor", backgroundColor ); - mStrokeColorIndex = shader.RegisterProperty( "uStrokeColor", strokeColor ); - - Actor parent = Self(); - - //Create the renderer - mBackgroundRenderer = Renderer::New( mesh, material ); - mBackgroundRenderer.SetDepthIndex( parent.GetHierarchyDepth() + BACKGROUND_DEPTH_INDEX ); - - //Create the actor - Actor backgroundActor = Actor::New(); - backgroundActor.SetSize( Vector3::ONE ); - - backgroundActor.SetPositionInheritanceMode( USE_PARENT_POSITION_PLUS_LOCAL_POSITION ); - backgroundActor.SetColorMode( USE_OWN_MULTIPLY_PARENT_ALPHA ); - - backgroundActor.AddRenderer( mBackgroundRenderer ); - - //Constraint scale of the mesh actor to the size of the control - Constraint constraint = Constraint::New( backgroundActor, - Actor::Property::SCALE, - EqualToConstraint() ); - - constraint.AddSource( ParentSource( Actor::Property::SIZE ) ); - constraint.Apply(); - - // The actor does not need to be inserted to guarantee order. - parent.Add( backgroundActor ); - } - } - else - { - // Set the new image to the sampler. - Image croppedImage = ninePatch.CreateCroppedBufferImage(); - - if( croppedImage ) - { - Material material = mBackgroundRenderer.GetMaterial(); - Sampler sampler = material.GetSamplerAt( 0u ); - sampler.SetImage( croppedImage ); - - // Set the new colors to the shader. - Shader shader = material.GetShader(); - shader.SetProperty( mBackgroundColorIndex, backgroundColor ); - shader.SetProperty( mStrokeColorIndex, strokeColor ); - } - } - } - else - { - SetBackgroundImage( image ); - } -} - -void TextSelectionPopup::RelayoutComplete( Actor actor ) -{ - if( mBackgroundVertexBuffer ) - { - Actor self = Self(); - - const float width = mNinePatchBorder / self.GetRelayoutSize( Dimension::WIDTH ); - const float height = mNinePatchBorder / self.GetRelayoutSize( Dimension::HEIGHT ); - - const float textCoord = mNinePatchBorderPercentage; - - Vector2 geometry[] = - { - Vector2( -0.5f, -0.5f ), // 0 - Vector2( 0.0f, 0.0f ), - Vector2( -0.5f + width, -0.5f ), // 1 - Vector2( 0.0f + textCoord, 0.0f ), - Vector2( 0.5f - width, -0.5f ), // 2 - Vector2( 1.0f - textCoord, 0.0f ), - Vector2( 0.5f, -0.5f ), // 3 - Vector2( 1.0f, 0.0f ), - Vector2( -0.5f, -0.5f + height ), // 4 - Vector2( 0.0f, 0.0f + textCoord ), - Vector2( -0.5f + width, -0.5f + height ), // 5 - Vector2( 0.0f + textCoord, 0.0f + textCoord ), - Vector2( 0.5f - width, -0.5f + height ), // 6 - Vector2( 1.0f - textCoord, 0.0f + textCoord ), - Vector2( 0.5f, -0.5f + height ), // 7 - Vector2( 1.0f, 0.0f + textCoord ), - Vector2( -0.5f, 0.5f - height ), // 8 - Vector2( 0.0f, 1.0f - textCoord ), - Vector2( -0.5f + width, 0.5f - height ), // 9 - Vector2( 0.0f + textCoord, 1.0f - textCoord ), - Vector2( 0.5f - width, 0.5f - height ), // 10 - Vector2( 1.0f - textCoord, 1.0f - textCoord ), - Vector2( 0.5f, 0.5f - height ), // 11 - Vector2( 1.0f, 1.0f - textCoord ), - Vector2( -0.5f, 0.5f ), // 12 - Vector2( 0.0f, 1.0f ), - Vector2( -0.5f + width, 0.5f ), // 13 - Vector2( 0.0f + textCoord, 1.0f ), - Vector2( 0.5f - width, 0.5f ), // 14 - Vector2( 1.0f - textCoord, 1.0f ), - Vector2( 0.5f, 0.5f ), // 15 - Vector2( 1.0f, 1.0f ) - }; - mBackgroundVertexBuffer.SetData( geometry ); - } -} - TextSelectionPopup::TextSelectionPopup( TextSelectionPopupCallbackInterface* callbackInterface ) : Control( ControlBehaviour( REQUIRES_STYLE_CHANGE_SIGNALS ) ), mToolbar(), - mBackgroundColorIndex( 0 ), - mStrokeColorIndex( 0 ), mPopupMaxSize(), mOptionMaxSize(), mOptionMinSize(), @@ -1090,8 +821,6 @@ TextSelectionPopup::TextSelectionPopup( TextSelectionPopupCallbackInterface* cal mClipboardOptionPriority( 6 ), mFadeInDuration(0.0f), mFadeOutDuration(0.0f), - mNinePatchBorder( 0.f ), - mNinePatchBorderPercentage( 0.f ), mShowIcons( false ), mShowCaptions( true ), mPopupShowing( false ), diff --git a/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.h b/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.h index 589063f..e4cef74 100644 --- a/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.h +++ b/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.h @@ -28,7 +28,6 @@ // EXTERNAL INCLUDES #include #include -#include namespace Dali { @@ -39,6 +38,9 @@ namespace Toolkit namespace Internal { +namespace +{ + enum PopupCustomisations { POPUP_MAXIMUM_SIZE, @@ -47,6 +49,8 @@ enum PopupCustomisations OPTION_DIVIDER_SIZE }; +} // namespace + class TextSelectionPopup : public Control { public: @@ -249,19 +253,6 @@ private: // Implementation void AddPopupOptionsToToolbar( bool showIcons, bool showCaptions ); /** - * @brief Sets the text's popup background image. - * - * @param[in] image The background's image. - * @param[in] backgroundColor The background's color. - * @param[in] strokeColor The stroke's color. - */ - void SetPopupBackgroundImage( Image image, - const Vector4& backgroundColor, - const Vector4& strokeColor ); - - void RelayoutComplete( Actor actor ); - - /** * Construct a new TextField. */ TextSelectionPopup( TextSelectionPopupCallbackInterface* callbackInterface ); @@ -292,12 +283,6 @@ private: // Data Image mSelectIconImage; Image mSelectAllIconImage; - Renderer mBackgroundRenderer; - PropertyBuffer mBackgroundVertexBuffer; - Property::Index mBackgroundColorIndex; - Property::Index mStrokeColorIndex; - Property::Map mBackgroundMap; - Size mPopupMaxSize; // Maximum size of the Popup Size mOptionMaxSize; // Maximum size of an Option button Size mOptionMinSize; // Minimum size of an Option button @@ -323,13 +308,11 @@ private: // Data float mFadeInDuration; // Duration of the animation to fade in the Popup float mFadeOutDuration; // Duration of the animation to fade out the Popup - float mNinePatchBorder; - float mNinePatchBorderPercentage; - bool mShowIcons:1; // Flag to show icons bool mShowCaptions:1; // Flag to show text captions bool mPopupShowing:1; // Flag to indicate Popup showing bool mButtonsChanged:1; // Flag to indicate the Popup Buttons have changed + }; } // namespace Internal diff --git a/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.cpp b/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.cpp index 80d4b66..1fd2160 100644 --- a/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.cpp @@ -26,7 +26,6 @@ #include #include #include -#include #include #include @@ -41,7 +40,7 @@ namespace Internal namespace { -const Dali::Vector2 DEFAULT_SCROLL_BAR_PADDING( 8.f, 6.f ); +const Dali::Vector2 DEFAULT_MAX_SIZE( 400.0f, 65.0f ); ///< The maximum size of the Toolbar. BaseHandle Create() { @@ -53,9 +52,6 @@ BaseHandle Create() DALI_TYPE_REGISTRATION_BEGIN( Toolkit::TextSelectionToolbar, Toolkit::Control, Create ); DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionToolbar, "max-size", VECTOR2, MAX_SIZE ) -DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionToolbar, "enable-overshoot", BOOLEAN, ENABLE_OVERSHOOT ) -DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionToolbar, "scroll-bar-padding", VECTOR2, SCROLL_BAR_PADDING ) -DALI_PROPERTY_REGISTRATION( Toolkit, TextSelectionToolbar, "scroll-view", MAP, SCROLL_VIEW ) DALI_TYPE_REGISTRATION_END() @@ -91,30 +87,7 @@ void TextSelectionToolbar::SetProperty( BaseObject* object, Property::Index inde impl.SetPopupMaxSize( value.Get< Vector2 >() ); break; } - case Toolkit::TextSelectionToolbar::Property::ENABLE_OVERSHOOT: - { - if( !impl.mScrollView ) - { - impl.mScrollView = Toolkit::ScrollView::New(); - } - impl.mScrollView.SetOvershootEnabled( value.Get< bool >() ); - break; - } - case Toolkit::TextSelectionToolbar::Property::SCROLL_BAR_PADDING: - { - impl.SetScrollBarPadding( value.Get< Vector2 >() ); - break; - } - case Toolkit::TextSelectionToolbar::Property::SCROLL_VIEW: - { - // Get a Property::Map from the property if possible. - Property::Map setPropertyMap; - if( value.Get( setPropertyMap ) ) - { - impl.ConfigureScrollview( setPropertyMap ); - } - break; - } + } // switch } // TextSelectionToolbar } @@ -136,16 +109,6 @@ Property::Value TextSelectionToolbar::GetProperty( BaseObject* object, Property: value = impl.GetPopupMaxSize(); break; } - case Toolkit::TextSelectionToolbar::Property::ENABLE_OVERSHOOT: - { - value = impl.mScrollView.IsOvershootEnabled(); - break; - } - case Toolkit::TextSelectionToolbar::Property::SCROLL_BAR_PADDING: - { - value = impl.GetScrollBarPadding(); - break; - } } // switch } return value; @@ -158,12 +121,9 @@ void TextSelectionToolbar::OnInitialize() void TextSelectionToolbar::OnRelayout( const Vector2& size, RelayoutContainer& container ) { - const float viewWidth = std::max( mTableOfButtons.GetNaturalSize().width, size.width ); - mRulerX->SetDomain( RulerDomain( 0.0, viewWidth, true ) ); + float width = std::max ( mTableOfButtons.GetNaturalSize().width, size.width ); + mRulerX->SetDomain( RulerDomain( 0.0, width, true ) ); mScrollView.SetRulerX( mRulerX ); - - const float barWidth = std::min( mTableOfButtons.GetNaturalSize().width, size.width ) - 2.f * mScrollBarPadding.x; - mScrollBarHorizontal.SetSize( Vector2( 0.0f, barWidth ) ); } void TextSelectionToolbar::OnStageConnection( int depth ) @@ -224,16 +184,6 @@ void TextSelectionToolbar::SetUpScrollView() mScrollView.SetRulerY( rulerY ); mScrollView.SetOvershootEnabled( true ); - - mScrollBarHorizontal = Toolkit::ScrollBar::New( Toolkit::ScrollBar::Horizontal ); - mScrollBarHorizontal.SetName( "Text popup scroll bar" ); - mScrollBarHorizontal.SetParentOrigin( ParentOrigin::BOTTOM_LEFT ); - mScrollBarHorizontal.SetAnchorPoint( AnchorPoint::TOP_LEFT ); - mScrollBarHorizontal.SetPosition( mScrollBarPadding.x, -mScrollBarPadding.y ); - mScrollBarHorizontal.SetResizePolicy( Dali::ResizePolicy::FIT_TO_CHILDREN, Dali::Dimension::WIDTH ); - mScrollBarHorizontal.SetOrientation( Quaternion( Radian( 1.5f * Math::PI ), Vector3::ZAXIS ) ); - mScrollBarHorizontal.GetPanGestureDetector().DetachAll(); - mScrollView.Add( mScrollBarHorizontal ); } void TextSelectionToolbar::SetUp() @@ -252,10 +202,7 @@ void TextSelectionToolbar::SetUp() stencil.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS ); stencil.SetParentOrigin( ParentOrigin::CENTER ); - if ( !mScrollView ) - { - mScrollView = Toolkit::ScrollView::New(); - } + mScrollView = Toolkit::ScrollView::New(); SetUpScrollView(); // Toolbar must start with at least one option, adding further options with increase it's size @@ -264,6 +211,7 @@ void TextSelectionToolbar::SetUp() mTableOfButtons.SetParentOrigin( ParentOrigin::CENTER_LEFT ); mTableOfButtons.SetAnchorPoint( AnchorPoint::CENTER_LEFT ); + mStencilLayer.Add( stencil ); mStencilLayer.Add( mScrollView ); mScrollView.Add( mTableOfButtons ); @@ -308,47 +256,9 @@ void TextSelectionToolbar::RaiseAbove( Layer target ) mStencilLayer.RaiseAbove( target ); } -void TextSelectionToolbar::SetScrollBarPadding( const Vector2& padding ) -{ - mScrollBarPadding = padding; - if( mScrollBarHorizontal ) - { - mScrollBarHorizontal.SetPosition( mScrollBarPadding.x, -mScrollBarPadding.y ); - } - - RelayoutRequest(); -} - -void TextSelectionToolbar::ConfigureScrollview( const Property::Map& properties ) -{ - // Set any properties specified for the label by iterating through all property key-value pairs. - for( unsigned int i = 0, mapCount = properties.Count(); i < mapCount; ++i ) - { - const StringValuePair& propertyPair( properties.GetPair( i ) ); - - // Convert the property string to a property index. - Property::Index setPropertyIndex = mScrollView.GetPropertyIndex( propertyPair.first ); - if( setPropertyIndex != Property::INVALID_INDEX ) - { - // If the conversion worked, we have a valid property index, - // Set the property to the new value. - mScrollView.SetProperty( setPropertyIndex, propertyPair.second ); - } - } - - RelayoutRequest(); -} - - -const Vector2& TextSelectionToolbar::GetScrollBarPadding() const -{ - return mScrollBarPadding; -} - TextSelectionToolbar::TextSelectionToolbar() : Control( ControlBehaviour( ControlBehaviour( REQUIRES_STYLE_CHANGE_SIGNALS ) ) ), mMaxSize (), - mScrollBarPadding( DEFAULT_SCROLL_BAR_PADDING ), mIndexInTable( 0 ), mDividerIndexes() { diff --git a/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.h b/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.h index a8575f9..29d25db 100644 --- a/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.h +++ b/dali-toolkit/internal/controls/text-controls/text-selection-toolbar-impl.h @@ -21,7 +21,6 @@ // INTERNAL INCLUDES #include #include -#include #include #include @@ -37,6 +36,11 @@ namespace Toolkit namespace Internal { +namespace +{ + +} // namespace + class TextSelectionToolbar : public Control { public: @@ -114,13 +118,6 @@ private: // From Control */ const Dali::Vector2& GetPopupMaxSize() const; -private: // Implementation - - /** - * @copydoc Toolkit::TextSelectionToolbar::ConfigureScrollview() - */ - void ConfigureScrollview( const Property::Map& properties ); - /** * @brief Set up scrollview to scroll Toolbar horizontally */ @@ -143,18 +140,6 @@ private: // Implementation */ void OnScrollCompleted( const Vector2& position ); - /** - * Sets the scroll bar padding. - * - * @param[in] padding The padding value. - */ - void SetScrollBarPadding( const Vector2& padding ); - - /** - * @return The padding value. - */ - const Vector2& GetScrollBarPadding() const; - private: // Implementation /** @@ -178,12 +163,11 @@ private: // Data Layer mStencilLayer; ///< The stencil layer Toolkit::TableView mTableOfButtons; ///< Actor which holds all the buttons, sensitivity can be set on buttons via this actor Toolkit::ScrollView mScrollView; ///< Provides scrolling of Toolbar when content does not fit. - Toolkit::ScrollBar mScrollBarHorizontal; ///< An horizontal scroll bar for the text's popup options. RulerPtr mRulerX; ///< Ruler to clamp horizontal scrolling. Updates on Relayout Size mMaxSize; ///< Max size of the Toolbar - Vector2 mScrollBarPadding; ///< The padding used to position the scroll indicator. unsigned int mIndexInTable; ///< Index in table to add option Dali::Vector< unsigned int > mDividerIndexes; ///< Vector of indexes in the Toolbar that contain dividers. + }; } // namespace Internal diff --git a/dali-toolkit/internal/file.list b/dali-toolkit/internal/file.list index 4631e35..3b0b3dd 100644 --- a/dali-toolkit/internal/file.list +++ b/dali-toolkit/internal/file.list @@ -24,6 +24,8 @@ toolkit_src_files = \ $(toolkit_src_dir)/controls/gaussian-blur-view/gaussian-blur-view-impl.cpp \ $(toolkit_src_dir)/controls/image-view/image-view-impl.cpp \ $(toolkit_src_dir)/controls/magnifier/magnifier-impl.cpp \ + $(toolkit_src_dir)/controls/model3d-view/model3d-view-impl.cpp \ + $(toolkit_src_dir)/controls/model3d-view/obj-loader.cpp \ $(toolkit_src_dir)/controls/popup/popup-impl.cpp \ $(toolkit_src_dir)/controls/popup/popup-style-impl.cpp \ $(toolkit_src_dir)/controls/page-turn-view/page-turn-portrait-view-impl.cpp \ diff --git a/dali-toolkit/internal/focus-manager/keyboard-focus-manager-impl.cpp b/dali-toolkit/internal/focus-manager/keyboard-focus-manager-impl.cpp index 524500f..0c37f7c 100644 --- a/dali-toolkit/internal/focus-manager/keyboard-focus-manager-impl.cpp +++ b/dali-toolkit/internal/focus-manager/keyboard-focus-manager-impl.cpp @@ -152,7 +152,7 @@ bool KeyboardFocusManager::DoSetCurrentFocusActor(const unsigned int actorID) if(actor.IsKeyboardFocusable()) { // Draw the focus indicator upon the focused actor - if(mFocusIndicatorActor) + if(mIsFocusIndicatorEnabled && mFocusIndicatorActor) { actor.Add(mFocusIndicatorActor); } diff --git a/dali-toolkit/internal/text/decorator/text-decorator.cpp b/dali-toolkit/internal/text/decorator/text-decorator.cpp index 53b3583..1f6ded8 100644 --- a/dali-toolkit/internal/text/decorator/text-decorator.cpp +++ b/dali-toolkit/internal/text/decorator/text-decorator.cpp @@ -85,6 +85,11 @@ Integration::Log::Filter* gLogFilter( Integration::Log::Filter::New(Debug::NoLog // Local Data namespace { + +const char* DEFAULT_GRAB_HANDLE_IMAGE_RELEASED( DALI_IMAGE_DIR "cursor_handler_center.png" ); + +const int DEFAULT_POPUP_OFFSET( -100.0f ); // Vertical offset of Popup from cursor or handles position. + const Dali::Vector3 DEFAULT_GRAB_HANDLE_RELATIVE_SIZE( 1.25f, 1.5f, 1.0f ); const Dali::Vector3 DEFAULT_SELECTION_HANDLE_RELATIVE_SIZE( 1.25f, 1.5f, 1.0f ); @@ -214,7 +219,6 @@ struct Decorator::Impl : public ConnectionTracker active( false ), visible( false ), pressed( false ), - verticallyFlippedPreferred( false ), horizontallyFlipped( false ), verticallyFlipped( false ) { @@ -232,20 +236,21 @@ struct Decorator::Impl : public ConnectionTracker bool active : 1; bool visible : 1; bool pressed : 1; - bool verticallyFlippedPreferred : 1; ///< Whether the handle is preferred to be vertically flipped. - bool horizontallyFlipped : 1; ///< Whether the handle has been horizontally flipped. - bool verticallyFlipped : 1; ///< Whether the handle has been vertically flipped. + bool horizontallyFlipped : 1; ///< Whether the handle has been horizontally flipped. + bool verticallyFlipped : 1; ///< Whether the handle has been vertically flipped. }; struct PopupImpl { PopupImpl() - : position() + : position(), + offset( DEFAULT_POPUP_OFFSET ) { } TextSelectionPopup actor; Vector3 position; + int offset; }; Impl( ControllerInterface& controller, @@ -283,7 +288,7 @@ struct Decorator::Impl : public ConnectionTracker { mQuadVertexFormat[ "aPosition" ] = Property::VECTOR2; mQuadIndexFormat[ "indices" ] = Property::INTEGER; - mHighlightMaterial = Material::New( Shader::New( VERTEX_SHADER, FRAGMENT_SHADER, Shader::HINT_MODIFIES_GEOMETRY) ); // HINT_MODIFIES_GEOMETRY used to disable culling optimisations + mHighlightMaterial = Material::New( Shader::New( VERTEX_SHADER, FRAGMENT_SHADER ) ); SetupTouchEvents(); } @@ -294,8 +299,6 @@ struct Decorator::Impl : public ConnectionTracker */ void Relayout( const Vector2& size ) { - mControlSize = size; - // TODO - Remove this if nothing is active CreateActiveLayer(); @@ -305,11 +308,13 @@ struct Decorator::Impl : public ConnectionTracker if( mPrimaryCursor ) { const CursorImpl& cursor = mCursor[PRIMARY_CURSOR]; - mPrimaryCursorVisible = ( cursor.position.x + mCursorWidth <= mControlSize.width ) && ( cursor.position.x >= 0.f ); + mPrimaryCursorVisible = ( cursor.position.x <= size.width ) && ( cursor.position.x >= 0.f ); if( mPrimaryCursorVisible ) { - mPrimaryCursor.SetPosition( cursor.position.x, - cursor.position.y ); + const Vector2& position = cursor.position; + + mPrimaryCursor.SetPosition( position.x, + position.y ); mPrimaryCursor.SetSize( Size( mCursorWidth, cursor.cursorHeight ) ); } mPrimaryCursor.SetVisible( mPrimaryCursorVisible && mCursorBlinkStatus ); @@ -317,7 +322,7 @@ struct Decorator::Impl : public ConnectionTracker if( mSecondaryCursor ) { const CursorImpl& cursor = mCursor[SECONDARY_CURSOR]; - mSecondaryCursorVisible = ( cursor.position.x + mCursorWidth <= mControlSize.width ) && ( cursor.position.x >= 0.f ); + mSecondaryCursorVisible = ( cursor.position.x <= size.width ) && ( cursor.position.x >= 0.f ); if( mSecondaryCursorVisible ) { mSecondaryCursor.SetPosition( cursor.position.x, @@ -329,10 +334,11 @@ struct Decorator::Impl : public ConnectionTracker // Show or hide the grab handle HandleImpl& grabHandle = mHandle[GRAB_HANDLE]; - bool newGrabHandlePosition = false; if( grabHandle.active ) { - const bool isVisible = ( grabHandle.position.x + floor( 0.5f * mCursorWidth ) <= mControlSize.width ) && ( grabHandle.position.x >= 0.f ); + const Vector2& position = grabHandle.position; + + const bool isVisible = ( position.x <= size.width ) && ( position.x >= 0.f ); if( isVisible ) { @@ -343,14 +349,8 @@ struct Decorator::Impl : public ConnectionTracker // Sets the grab handle image according if it's pressed, flipped, etc. SetHandleImage( GRAB_HANDLE ); - - newGrabHandlePosition = true; - } - - if( grabHandle.actor ) - { - grabHandle.actor.SetVisible( isVisible ); } + grabHandle.actor.SetVisible( isVisible ); } else if( grabHandle.actor ) { @@ -360,12 +360,13 @@ struct Decorator::Impl : public ConnectionTracker // Show or hide the selection handles/highlight HandleImpl& primary = mHandle[ LEFT_SELECTION_HANDLE ]; HandleImpl& secondary = mHandle[ RIGHT_SELECTION_HANDLE ]; - bool newPrimaryHandlePosition = false; - bool newSecondaryHandlePosition = false; if( primary.active || secondary.active ) { - const bool isPrimaryVisible = ( primary.position.x <= mControlSize.width ) && ( primary.position.x >= 0.f ); - const bool isSecondaryVisible = ( secondary.position.x <= mControlSize.width ) && ( secondary.position.x >= 0.f ); + const Vector2& primaryPosition = primary.position; + const Vector2& secondaryPosition = secondary.position; + + const bool isPrimaryVisible = ( primaryPosition.x <= size.width ) && ( primaryPosition.x >= 0.f ); + const bool isSecondaryVisible = ( secondaryPosition.x <= size.width ) && ( secondaryPosition.x >= 0.f ); if( isPrimaryVisible || isSecondaryVisible ) { @@ -379,8 +380,6 @@ struct Decorator::Impl : public ConnectionTracker SetHandleImage( LEFT_SELECTION_HANDLE ); SetSelectionHandleMarkerSize( primary ); - - newPrimaryHandlePosition = true; } if( isSecondaryVisible ) @@ -391,19 +390,10 @@ struct Decorator::Impl : public ConnectionTracker SetHandleImage( RIGHT_SELECTION_HANDLE ); SetSelectionHandleMarkerSize( secondary ); - - newSecondaryHandlePosition = true; } } - - if( primary.actor ) - { - primary.actor.SetVisible( isPrimaryVisible ); - } - if( secondary.actor ) - { - secondary.actor.SetVisible( isSecondaryVisible ); - } + primary.actor.SetVisible( isPrimaryVisible ); + secondary.actor.SetVisible( isSecondaryVisible ); CreateHighlight(); UpdateHighlight(); @@ -424,18 +414,9 @@ struct Decorator::Impl : public ConnectionTracker } } - if( newGrabHandlePosition || - newPrimaryHandlePosition || - newSecondaryHandlePosition ) - { - // Setup property notifications to find whether the handles leave the boundaries of the current display. - SetupActiveLayerPropertyNotifications(); - } - if( mActiveCopyPastePopup ) { ShowPopup(); - mPopupSetNewPosition = true; } else { @@ -475,40 +456,32 @@ struct Decorator::Impl : public ConnectionTracker void DeterminePositionPopup() { - if( !mActiveCopyPastePopup ) + if ( !mActiveCopyPastePopup ) { return; } - // Retrieves the popup's size after relayout. - const Vector3 popupSize = Vector3( mCopyPastePopup.actor.GetRelayoutSize( Dimension::WIDTH ), mCopyPastePopup.actor.GetRelayoutSize( Dimension::HEIGHT ), 0.0f ); - if( mPopupSetNewPosition ) { - const HandleImpl& primaryHandle = mHandle[LEFT_SELECTION_HANDLE]; - const HandleImpl& secondaryHandle = mHandle[RIGHT_SELECTION_HANDLE]; - const HandleImpl& grabHandle = mHandle[GRAB_HANDLE]; - const CursorImpl& cursor = mCursor[PRIMARY_CURSOR]; - - if( primaryHandle.active || secondaryHandle.active ) + if ( mHandle[LEFT_SELECTION_HANDLE].active || mHandle[RIGHT_SELECTION_HANDLE].active ) { - // Calculates the popup's position if selection handles are active. - const float minHandleXPosition = std::min( primaryHandle.position.x, secondaryHandle.position.x ); - const float maxHandleXPosition = std::max( primaryHandle.position.x, secondaryHandle.position.x ); - const float maxHandleHeight = std::max( primaryHandle.size.height, secondaryHandle.size.height ); + float minHandleXPosition = std::min ( mHandle[LEFT_SELECTION_HANDLE].position.x, mHandle[RIGHT_SELECTION_HANDLE].position.x ); + float maxHandleXPosition = std::max ( mHandle[LEFT_SELECTION_HANDLE].position.x, mHandle[RIGHT_SELECTION_HANDLE].position.x ); - mCopyPastePopup.position.x = minHandleXPosition + ( ( maxHandleXPosition - minHandleXPosition ) * 0.5f ); - mCopyPastePopup.position.y = -0.5f * popupSize.height - maxHandleHeight + std::min( primaryHandle.position.y, secondaryHandle.position.y ); + float minHandleYPosition = std::min ( mHandle[LEFT_SELECTION_HANDLE].position.y, mHandle[RIGHT_SELECTION_HANDLE].position.y ); + + mCopyPastePopup.position.x = minHandleXPosition + ( ( maxHandleXPosition - minHandleXPosition ) *0.5f ); + mCopyPastePopup.position.y = minHandleYPosition + mCopyPastePopup.offset; } else { - // Calculates the popup's position if the grab handle is active. - mCopyPastePopup.position = Vector3( cursor.position.x, -0.5f * popupSize.height - grabHandle.size.height + cursor.position.y, 0.0f ); + mCopyPastePopup.position = Vector3( mCursor[PRIMARY_CURSOR].position.x, mCursor[PRIMARY_CURSOR].position.y -100.0f , 0.0f ); //todo 100 to be an offset Property } } - // Checks if there is enough space above the text control. If not it places the popup under it. - GetConstrainedPopupPosition( mCopyPastePopup.position, popupSize * AnchorPoint::CENTER, mActiveLayer, mBoundingBox ); + Vector3 popupSize = Vector3( mCopyPastePopup.actor.GetRelayoutSize( Dimension::WIDTH ), mCopyPastePopup.actor.GetRelayoutSize( Dimension::HEIGHT ), 0.0f ); + + GetConstrainedPopupPosition( mCopyPastePopup.position, popupSize, AnchorPoint::CENTER, mActiveLayer, mBoundingBox ); SetUpPopupPositionNotifications(); @@ -528,7 +501,7 @@ struct Decorator::Impl : public ConnectionTracker cursor = CreateSolidColorActor( color ); cursor.SetSortModifier( DECORATION_DEPTH_INDEX ); cursor.SetParentOrigin( ParentOrigin::TOP_LEFT ); // Need to set the default parent origin as CreateSolidColorActor() sets a different one. - cursor.SetAnchorPoint( AnchorPoint::TOP_LEFT ); + cursor.SetAnchorPoint( AnchorPoint::TOP_RIGHT ); } // Add or Remove cursor(s) from parent @@ -646,7 +619,7 @@ struct Decorator::Impl : public ConnectionTracker void SetSelectionHandleMarkerSize( HandleImpl& handle ) { - if( handle.markerActor ) + if ( handle.markerActor ) { handle.markerActor.SetSize( 0, handle.lineHeight ); } @@ -657,6 +630,11 @@ struct Decorator::Impl : public ConnectionTracker HandleImpl& grabHandle = mHandle[GRAB_HANDLE]; if( !grabHandle.actor ) { + if( !mHandleImages[GRAB_HANDLE][HANDLE_IMAGE_RELEASED] ) + { + SetHandleImage( GRAB_HANDLE, HANDLE_IMAGE_RELEASED, ResourceImage::New( DEFAULT_GRAB_HANDLE_IMAGE_RELEASED ) ); + } + grabHandle.actor = ImageActor::New( mHandleImages[GRAB_HANDLE][HANDLE_IMAGE_RELEASED] ); grabHandle.actor.SetSortModifier( DECORATION_DEPTH_INDEX ); grabHandle.actor.SetAnchorPoint( AnchorPoint::TOP_CENTER ); @@ -699,7 +677,7 @@ struct Decorator::Impl : public ConnectionTracker void CreateHandleMarker( HandleImpl& handle, Image& image, HandleType handleType ) { - if( image ) + if ( image ) { handle.markerActor = ImageActor::New( image ); handle.markerActor.SetColor( mHandleColor ); @@ -707,12 +685,12 @@ struct Decorator::Impl : public ConnectionTracker handle.markerActor.SetResizePolicy ( ResizePolicy::FIXED, Dimension::HEIGHT ); - if( LEFT_SELECTION_HANDLE == handleType ) + if ( LEFT_SELECTION_HANDLE == handleType ) { handle.markerActor.SetAnchorPoint( AnchorPoint::BOTTOM_RIGHT ); handle.markerActor.SetParentOrigin( ParentOrigin::TOP_RIGHT ); } - else if( RIGHT_SELECTION_HANDLE == handleType ) + else if ( RIGHT_SELECTION_HANDLE == handleType ) { handle.markerActor.SetAnchorPoint( AnchorPoint::BOTTOM_LEFT ); handle.markerActor.SetParentOrigin( ParentOrigin::TOP_LEFT ); @@ -793,14 +771,16 @@ struct Decorator::Impl : public ConnectionTracker void CalculateHandleWorldCoordinates( HandleImpl& handle, Vector2& position ) { - // Gets the world position of the active layer. The active layer is where the handles are added. + // Get the world position of the active layer const Vector3 parentWorldPosition = mActiveLayer.GetCurrentWorldPosition(); + // Get the size of the UI control. + Vector2 targetSize; + mController.GetTargetSize( targetSize ); + // The grab handle position in world coords. - // The active layer's world position is the center of the active layer. The origin of the - // coord system of the handles is the top left of the active layer. - position.x = parentWorldPosition.x - 0.5f * mControlSize.width + handle.position.x; - position.y = parentWorldPosition.y - 0.5f * mControlSize.height + handle.position.y; + position.x = parentWorldPosition.x - 0.5f * targetSize.width + handle.position.x; + position.y = parentWorldPosition.y - 0.5f * targetSize.height + handle.position.y + handle.lineHeight; } void SetGrabHandlePosition() @@ -808,21 +788,13 @@ struct Decorator::Impl : public ConnectionTracker // Reference to the grab handle. HandleImpl& grabHandle = mHandle[GRAB_HANDLE]; - // Transforms the handle position into world coordinates. - // @note This is not the same value as grabHandle.actor.GetCurrentWorldPosition() - // as it's transforming the handle's position set by the text-controller and not - // the final position set to the actor. Another difference is the GetCurrentWorldPosition() - // retrieves the position of the center of the actor but the handle's position set - // by the text controller is not the center of the actor. + // The grab handle position in world coords. Vector2 grabHandleWorldPosition; CalculateHandleWorldCoordinates( grabHandle, grabHandleWorldPosition ); // Check if the grab handle exceeds the boundaries of the decoration box. // At the moment only the height is checked for the grab handle. - - grabHandle.verticallyFlipped = ( grabHandle.verticallyFlippedPreferred && - ( ( grabHandleWorldPosition.y - grabHandle.size.height ) > mBoundingBox.y ) ) || - ( grabHandleWorldPosition.y + grabHandle.lineHeight + grabHandle.size.height > mBoundingBox.w ); + grabHandle.verticallyFlipped = ( grabHandleWorldPosition.y + grabHandle.size.height > mBoundingBox.w ); // The grab handle 'y' position in local coords. // If the grab handle exceeds the bottom of the decoration box, @@ -830,7 +802,7 @@ struct Decorator::Impl : public ConnectionTracker // The SetGrabHandleImage() method will change the orientation. const float yLocalPosition = grabHandle.verticallyFlipped ? grabHandle.position.y : grabHandle.position.y + grabHandle.lineHeight; - grabHandle.actor.SetPosition( grabHandle.position.x + floor( 0.5f * mCursorWidth ), + grabHandle.actor.SetPosition( grabHandle.position.x - floor( 0.5f * mCursorWidth ), yLocalPosition ); // TODO : Fix for multiline. } @@ -841,16 +813,11 @@ struct Decorator::Impl : public ConnectionTracker // Reference to the selection handle. HandleImpl& handle = mHandle[type]; - // Transforms the handle position into world coordinates. - // @note This is not the same value as handle.actor.GetCurrentWorldPosition() - // as it's transforming the handle's position set by the text-controller and not - // the final position set to the actor. Another difference is the GetCurrentWorldPosition() - // retrieves the position of the center of the actor but the handle's position set - // by the text controller is not the center of the actor. + // Get the world coordinates of the handle position. Vector2 handleWorldPosition; CalculateHandleWorldCoordinates( handle, handleWorldPosition ); - // Whether to flip the handle (horizontally). + // Whether to flip the handle. bool flipHandle = isPrimaryHandle ? mFlipLeftSelectionHandleDirection : mFlipRightSelectionHandleDirection; // Whether to flip the handles if they are crossed. @@ -863,23 +830,9 @@ struct Decorator::Impl : public ConnectionTracker // Does not flip if both conditions are true (double flip) flipHandle = flipHandle != ( crossFlip || mHandlePreviousCrossed ); - // Will flip the handles vertically if the user prefers it. - bool verticallyFlippedPreferred = handle.verticallyFlippedPreferred; - - if( crossFlip || mHandlePreviousCrossed ) - { - if( isPrimaryHandle ) - { - verticallyFlippedPreferred = mHandle[RIGHT_SELECTION_HANDLE].verticallyFlippedPreferred; - } - else - { - verticallyFlippedPreferred = mHandle[LEFT_SELECTION_HANDLE].verticallyFlippedPreferred; - } - } - // Check if the selection handle exceeds the boundaries of the decoration box. const bool exceedsLeftEdge = ( isPrimaryHandle ? !flipHandle : flipHandle ) && ( handleWorldPosition.x - handle.size.width < mBoundingBox.x ); + const bool exceedsRightEdge = ( isPrimaryHandle ? flipHandle : !flipHandle ) && ( handleWorldPosition.x + handle.size.width > mBoundingBox.z ); // Does not flip if both conditions are true (double flip) @@ -907,9 +860,7 @@ struct Decorator::Impl : public ConnectionTracker } // Whether to flip the handle vertically. - handle.verticallyFlipped = ( verticallyFlippedPreferred && - ( ( handleWorldPosition.y - handle.size.height ) > mBoundingBox.y ) ) || - ( handleWorldPosition.y + handle.lineHeight + handle.size.height > mBoundingBox.w ); + handle.verticallyFlipped = ( handleWorldPosition.y + handle.size.height > mBoundingBox.w ); // The primary selection handle 'y' position in local coords. // If the handle exceeds the bottom of the decoration box, @@ -939,27 +890,18 @@ struct Decorator::Impl : public ConnectionTracker } // Chooses between the released or pressed image. It checks whether the pressed image exists. - if( handle.actor ) - { - const HandleImageType imageType = ( handle.pressed ? ( mHandleImages[type][HANDLE_IMAGE_PRESSED] ? HANDLE_IMAGE_PRESSED : HANDLE_IMAGE_RELEASED ) : HANDLE_IMAGE_RELEASED ); + const HandleImageType imageType = ( handle.pressed ? ( mHandleImages[type][HANDLE_IMAGE_PRESSED] ? HANDLE_IMAGE_PRESSED : HANDLE_IMAGE_RELEASED ) : HANDLE_IMAGE_RELEASED ); - handle.actor.SetImage( mHandleImages[type][imageType] ); - } + handle.actor.SetImage( mHandleImages[type][imageType] ); if( HANDLE_TYPE_COUNT != markerType ) { - if( handle.markerActor ) - { - const HandleImageType markerImageType = ( handle.pressed ? ( mHandleImages[markerType][HANDLE_IMAGE_PRESSED] ? HANDLE_IMAGE_PRESSED : HANDLE_IMAGE_RELEASED ) : HANDLE_IMAGE_RELEASED ); - handle.markerActor.SetImage( mHandleImages[markerType][markerImageType] ); - } + const HandleImageType markerImageType = ( handle.pressed ? ( mHandleImages[markerType][HANDLE_IMAGE_PRESSED] ? HANDLE_IMAGE_PRESSED : HANDLE_IMAGE_RELEASED ) : HANDLE_IMAGE_RELEASED ); + handle.markerActor.SetImage( mHandleImages[markerType][markerImageType] ); } // Whether to flip the handle vertically. - if( handle.actor ) - { - handle.actor.SetOrientation( handle.verticallyFlipped ? ANGLE_180 : ANGLE_0, Vector3::XAXIS ); - } + handle.actor.SetOrientation( handle.verticallyFlipped ? ANGLE_180 : ANGLE_0, Vector3::XAXIS ); } void CreateHighlight() @@ -1246,234 +1188,30 @@ struct Decorator::Impl : public ConnectionTracker return true; } - void HandleResetPosition( PropertyNotification& source ) - { - const HandleImpl& grabHandle = mHandle[GRAB_HANDLE]; - - if( grabHandle.active ) - { - // Sets the grab handle position and calculates if it needs to be vertically flipped if it exceeds the boundary box. - SetGrabHandlePosition(); - - // Sets the grab handle image according if it's pressed, flipped, etc. - SetHandleImage( GRAB_HANDLE ); - } - else - { - // Sets the primary selection handle position and calculates if it needs to be vertically flipped if it exceeds the boundary box. - SetSelectionHandlePosition( LEFT_SELECTION_HANDLE ); - - // Sets the primary handle image according if it's pressed, flipped, etc. - SetHandleImage( LEFT_SELECTION_HANDLE ); - - // Sets the secondary selection handle position and calculates if it needs to be vertically flipped if it exceeds the boundary box. - SetSelectionHandlePosition( RIGHT_SELECTION_HANDLE ); - - // Sets the secondary handle image according if it's pressed, flipped, etc. - SetHandleImage( RIGHT_SELECTION_HANDLE ); - } - } - - void SetupActiveLayerPropertyNotifications() - { - if( !mActiveLayer ) - { - return; - } - - // Vertical notifications. - - // Disconnect any previous connected callback. - if( mVerticalLessThanNotification ) - { - mVerticalLessThanNotification.NotifySignal().Disconnect( this, &Decorator::Impl::HandleResetPosition ); - mActiveLayer.RemovePropertyNotification( mVerticalLessThanNotification ); - } - - if( mVerticalGreaterThanNotification ) - { - mVerticalGreaterThanNotification.NotifySignal().Disconnect( this, &Decorator::Impl::HandleResetPosition ); - mActiveLayer.RemovePropertyNotification( mVerticalGreaterThanNotification ); - } - - const HandleImpl& grabHandle = mHandle[GRAB_HANDLE]; - const HandleImpl& primaryHandle = mHandle[LEFT_SELECTION_HANDLE]; - const HandleImpl& secondaryHandle = mHandle[RIGHT_SELECTION_HANDLE]; - - if( grabHandle.active ) - { - if( grabHandle.verticallyFlipped ) - { - // The grab handle is vertically flipped. Never is going to exceed the bottom edje of the display. - mVerticalGreaterThanNotification.Reset(); - - // The vertical distance from the center of the active layer to the top edje of the display. - const float topHeight = 0.5f * mControlSize.height - grabHandle.position.y + grabHandle.size.height; - - mVerticalLessThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_Y, - LessThanCondition( mBoundingBox.y + topHeight ) ); - - // Notifies the change from false to true and from true to false. - mVerticalLessThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mVerticalLessThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - } - else - { - // The grab handle is not vertically flipped. Never is going to exceed the top edje of the display. - mVerticalLessThanNotification.Reset(); - - // The vertical distance from the center of the active layer to the bottom edje of the display. - const float bottomHeight = -0.5f * mControlSize.height + grabHandle.position.y + grabHandle.lineHeight + grabHandle.size.height; - - mVerticalGreaterThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_Y, - GreaterThanCondition( mBoundingBox.w - bottomHeight ) ); - - // Notifies the change from false to true and from true to false. - mVerticalGreaterThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mVerticalGreaterThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - } - } - else // The selection handles are active - { - if( primaryHandle.verticallyFlipped && secondaryHandle.verticallyFlipped ) - { - // Both selection handles are vertically flipped. Never are going to exceed the bottom edje of the display. - mVerticalGreaterThanNotification.Reset(); - - // The vertical distance from the center of the active layer to the top edje of the display. - const float topHeight = 0.5f * mControlSize.height + std::max( -primaryHandle.position.y + primaryHandle.size.height, -secondaryHandle.position.y + secondaryHandle.size.height ); - - mVerticalLessThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_Y, - LessThanCondition( mBoundingBox.y + topHeight ) ); - - // Notifies the change from false to true and from true to false. - mVerticalLessThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mVerticalLessThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - } - else if( !primaryHandle.verticallyFlipped && !secondaryHandle.verticallyFlipped ) - { - // Both selection handles aren't vertically flipped. Never are going to exceed the top edje of the display. - mVerticalLessThanNotification.Reset(); - - // The vertical distance from the center of the active layer to the bottom edje of the display. - const float bottomHeight = -0.5f * mControlSize.height + std::max( primaryHandle.position.y + primaryHandle.lineHeight + primaryHandle.size.height, - secondaryHandle.position.y + secondaryHandle.lineHeight + secondaryHandle.size.height ); - - mVerticalGreaterThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_Y, - GreaterThanCondition( mBoundingBox.w - bottomHeight ) ); - - // Notifies the change from false to true and from true to false. - mVerticalGreaterThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mVerticalGreaterThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - } - else - { - // Only one of the selection handles is vertically flipped. Both vertical notifications are needed. - - // The vertical distance from the center of the active layer to the top edje of the display. - const float topHeight = 0.5f * mControlSize.height + ( primaryHandle.verticallyFlipped ? - -primaryHandle.position.y + primaryHandle.size.height : - -secondaryHandle.position.y + secondaryHandle.size.height ); - - mVerticalLessThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_Y, - LessThanCondition( mBoundingBox.y + topHeight ) ); - - // Notifies the change from false to true and from true to false. - mVerticalLessThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mVerticalLessThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - - // The vertical distance from the center of the active layer to the bottom edje of the display. - const float bottomHeight = -0.5f * mControlSize.height + ( primaryHandle.verticallyFlipped ? - secondaryHandle.position.y + secondaryHandle.lineHeight + secondaryHandle.size.height : - primaryHandle.position.y + primaryHandle.lineHeight + primaryHandle.size.height ); - - mVerticalGreaterThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_Y, - GreaterThanCondition( mBoundingBox.w - bottomHeight ) ); - - // Notifies the change from false to true and from true to false. - mVerticalGreaterThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mVerticalGreaterThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - } - } - - // Horizontal notifications. - - // Disconnect any previous connected callback. - if( mHorizontalLessThanNotification ) - { - mHorizontalLessThanNotification.NotifySignal().Disconnect( this, &Decorator::Impl::HandleResetPosition ); - mActiveLayer.RemovePropertyNotification( mHorizontalLessThanNotification ); - } - - if( mHorizontalGreaterThanNotification ) - { - mHorizontalGreaterThanNotification.NotifySignal().Disconnect( this, &Decorator::Impl::HandleResetPosition ); - mActiveLayer.RemovePropertyNotification( mHorizontalGreaterThanNotification ); - } - - if( primaryHandle.active || secondaryHandle.active ) - { - // The horizontal distance from the center of the active layer to the left edje of the display. - const float leftWidth = 0.5f * mControlSize.width + std::max( -primaryHandle.position.x + primaryHandle.size.width, - -secondaryHandle.position.x + secondaryHandle.size.width ); - - mHorizontalLessThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_X, - LessThanCondition( mBoundingBox.x + leftWidth ) ); - - // Notifies the change from false to true and from true to false. - mHorizontalLessThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mHorizontalLessThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - - // The horizontal distance from the center of the active layer to the right edje of the display. - const float rightWidth = -0.5f * mControlSize.width + std::max( primaryHandle.position.x + primaryHandle.size.width, - secondaryHandle.position.x + secondaryHandle.size.width ); - - mHorizontalGreaterThanNotification = mActiveLayer.AddPropertyNotification( Actor::Property::WORLD_POSITION_X, - GreaterThanCondition( mBoundingBox.z - rightWidth ) ); - - // Notifies the change from false to true and from true to false. - mHorizontalGreaterThanNotification.SetNotifyMode( PropertyNotification::NotifyOnChanged ); - - // Connects the signals with the callbacks. - mHorizontalGreaterThanNotification.NotifySignal().Connect( this, &Decorator::Impl::HandleResetPosition ); - } - } - // Popup float AlternatePopUpPositionRelativeToCursor() { - float alternativePosition = 0.0f; + float alternativePosition=0.0f;; - const float popupHeight = mCopyPastePopup.actor.GetRelayoutSize( Dimension::HEIGHT ); + if ( mPrimaryCursor ) // Secondary cursor not used for paste + { + Cursor cursor = PRIMARY_CURSOR; + alternativePosition = mCursor[cursor].position.y; + } - const HandleImpl& primaryHandle = mHandle[LEFT_SELECTION_HANDLE]; - const HandleImpl& secondaryHandle = mHandle[RIGHT_SELECTION_HANDLE]; - const HandleImpl& grabHandle = mHandle[GRAB_HANDLE]; - const CursorImpl& cursor = mCursor[PRIMARY_CURSOR]; + const float popupHeight = 120.0f; // todo Set as a MaxSize Property in Control or retrieve from CopyPastePopup class. - if( primaryHandle.active || secondaryHandle.active ) + if( mHandle[GRAB_HANDLE].active ) { - const float maxHandleHeight = std::max( primaryHandle.size.height, secondaryHandle.size.height ); - alternativePosition = 0.5f * popupHeight + cursor.lineHeight + maxHandleHeight + std::min( primaryHandle.position.y, secondaryHandle.position.y ); + // If grab handle enabled then position pop-up below the grab handle. + const Vector2 grabHandleSize( 59.0f, 56.0f ); // todo + const float BOTTOM_HANDLE_BOTTOM_OFFSET = 1.5; //todo Should be a property + alternativePosition += grabHandleSize.height + popupHeight + BOTTOM_HANDLE_BOTTOM_OFFSET ; } else { - alternativePosition = 0.5f * popupHeight + cursor.lineHeight + grabHandle.size.height + cursor.position.y; + alternativePosition += popupHeight; } return alternativePosition; @@ -1481,7 +1219,7 @@ struct Decorator::Impl : public ConnectionTracker void PopUpLeavesVerticalBoundary( PropertyNotification& source ) { - float alternativeYPosition = 0.0f; + float alternativeYPosition=0.0f; // todo use AlternatePopUpPositionRelativeToSelectionHandles() if text is highlighted // if can't be positioned above, then position below row. alternativeYPosition = AlternatePopUpPositionRelativeToCursor(); @@ -1489,28 +1227,31 @@ struct Decorator::Impl : public ConnectionTracker mCopyPastePopup.actor.SetY( alternativeYPosition ); } - void SetUpPopupPositionNotifications() + + void SetUpPopupPositionNotifications( ) { // Note Property notifications ignore any set anchor point so conditions must allow for this. Default is Top Left. // Exceeding vertical boundary - const float popupHeight = mCopyPastePopup.actor.GetRelayoutSize( Dimension::HEIGHT ); + float popupHeight = mCopyPastePopup.actor.GetRelayoutSize( Dimension::HEIGHT); PropertyNotification verticalExceedNotification = mCopyPastePopup.actor.AddPropertyNotification( Actor::Property::WORLD_POSITION_Y, - OutsideCondition( mBoundingBox.y + popupHeight * 0.5f, - mBoundingBox.w - popupHeight * 0.5f ) ); + OutsideCondition( mBoundingBox.y + popupHeight * 0.5f, + mBoundingBox.w - popupHeight * 0.5f ) ); verticalExceedNotification.NotifySignal().Connect( this, &Decorator::Impl::PopUpLeavesVerticalBoundary ); } - void GetConstrainedPopupPosition( Vector3& requiredPopupPosition, const Vector3& popupDistanceFromAnchorPoint, Actor parent, const Vector4& boundingRectangleWorld ) + void GetConstrainedPopupPosition( Vector3& requiredPopupPosition, Vector3& popupSize, Vector3 anchorPoint, Actor& parent, const Vector4& boundingRectangleWorld ) { DALI_ASSERT_DEBUG ( "Popup parent not on stage" && parent.OnStage() ) // Parent must already by added to Stage for these Get calls to work - const Vector3 parentWorldPositionLeftAnchor = parent.GetCurrentWorldPosition() - parent.GetCurrentSize() * parent.GetCurrentAnchorPoint(); - const Vector3 popupWorldPosition = parentWorldPositionLeftAnchor + requiredPopupPosition; // Parent World position plus popup local position gives World Position + Vector3 parentAnchorPoint = parent.GetCurrentAnchorPoint(); + Vector3 parentWorldPositionLeftAnchor = parent.GetCurrentWorldPosition() - parent.GetCurrentSize()*parentAnchorPoint; + Vector3 popupWorldPosition = parentWorldPositionLeftAnchor + requiredPopupPosition; // Parent World position plus popup local position gives World Position + Vector3 popupDistanceFromAnchorPoint = popupSize*anchorPoint; // Calculate distance to move popup (in local space) so fits within the boundary float xOffSetToKeepWithinBounds = 0.0f; @@ -1518,13 +1259,13 @@ struct Decorator::Impl : public ConnectionTracker { xOffSetToKeepWithinBounds = boundingRectangleWorld.x - ( popupWorldPosition.x - popupDistanceFromAnchorPoint.x ); } - else if( popupWorldPosition.x + popupDistanceFromAnchorPoint.x > boundingRectangleWorld.z ) + else if ( popupWorldPosition.x + popupDistanceFromAnchorPoint.x > boundingRectangleWorld.z ) { xOffSetToKeepWithinBounds = boundingRectangleWorld.z - ( popupWorldPosition.x + popupDistanceFromAnchorPoint.x ); } // Ensure initial display of Popup is in alternative position if can not fit above. As Property notification will be a frame behind. - if( popupWorldPosition.y - popupDistanceFromAnchorPoint.y < boundingRectangleWorld.y ) + if ( popupWorldPosition.y - popupDistanceFromAnchorPoint.y < boundingRectangleWorld.y ) { requiredPopupPosition.y = AlternatePopUpPositionRelativeToCursor(); } @@ -1532,8 +1273,8 @@ struct Decorator::Impl : public ConnectionTracker requiredPopupPosition.x = requiredPopupPosition.x + xOffSetToKeepWithinBounds; // Prevent pixel mis-alignment by rounding down. - requiredPopupPosition.x = floor( requiredPopupPosition.x ); - requiredPopupPosition.y = floor( requiredPopupPosition.y ); + requiredPopupPosition.x = static_cast( requiredPopupPosition.x ); + requiredPopupPosition.y = static_cast( requiredPopupPosition.y ); } void SetHandleImage( HandleType handleType, HandleImageType handleImageType, Dali::Image image ) @@ -1630,15 +1371,11 @@ struct Decorator::Impl : public ConnectionTracker Timer mCursorBlinkTimer; ///< Timer to signal cursor to blink Timer mScrollTimer; ///< Timer used to scroll the text when the grab handle is moved close to the edges. - Layer mActiveLayer; ///< Layer for active handles and alike that ensures they are above all else. - PropertyNotification mVerticalLessThanNotification; ///< Notifies when the 'y' coord of the active layer is less than a given value. - PropertyNotification mVerticalGreaterThanNotification; ///< Notifies when the 'y' coord of the active layer is grater than a given value. - PropertyNotification mHorizontalLessThanNotification; ///< Notifies when the 'x' coord of the active layer is less than a given value. - PropertyNotification mHorizontalGreaterThanNotification; ///< Notifies when the 'x' coord of the active layer is grater than a given value. - ImageActor mPrimaryCursor; - ImageActor mSecondaryCursor; + Layer mActiveLayer; ///< Layer for active handles and alike that ensures they are above all else. + ImageActor mPrimaryCursor; + ImageActor mSecondaryCursor; - Actor mHighlightActor; ///< Actor to display highlight + Actor mHighlightActor; ///< Actor to display highlight Renderer mHighlightRenderer; Material mHighlightMaterial; ///< Material used for highlight Property::Map mQuadVertexFormat; @@ -1661,7 +1398,6 @@ struct Decorator::Impl : public ConnectionTracker Vector4 mBoundingBox; ///< The bounding box in world coords. Vector4 mHighlightColor; ///< Color of the highlight Vector2 mHighlightPosition; ///< The position of the highlight actor. - Vector2 mControlSize; ///< The control's size. Set by the Relayout. unsigned int mActiveCursor; unsigned int mCursorBlinkInterval; @@ -1873,7 +1609,7 @@ const Vector4& Decorator::GetHandleColor() const void Decorator::SetPosition( HandleType handleType, float x, float y, float height ) { - // Adjust handle's displacement + // Adjust grab handle displacement Impl::HandleImpl& handle = mImpl->mHandle[handleType]; handle.grabDisplacementX -= x - handle.position.x; @@ -1898,16 +1634,6 @@ const Vector2& Decorator::GetPosition( HandleType handleType ) const return mImpl->mHandle[handleType].position; } -void Decorator::FlipHandleVertically( HandleType handleType, bool flip ) -{ - mImpl->mHandle[handleType].verticallyFlippedPreferred = flip; -} - -bool Decorator::IsHandleVerticallyFlipped( HandleType handleType ) const -{ - return mImpl->mHandle[handleType].verticallyFlippedPreferred; -} - void Decorator::FlipSelectionHandlesOnCrossEnabled( bool enable ) { mImpl->mFlipSelectionHandlesOnCross = enable; diff --git a/dali-toolkit/internal/text/decorator/text-decorator.h b/dali-toolkit/internal/text/decorator/text-decorator.h index 4bcd012..4e36fa7 100644 --- a/dali-toolkit/internal/text/decorator/text-decorator.h +++ b/dali-toolkit/internal/text/decorator/text-decorator.h @@ -397,23 +397,6 @@ public: const Vector2& GetPosition( HandleType handleType ) const; /** - * @brief Whether to flip vertically a handle. - * - * @param[in] handleType The handle to flip vertically. - * @param[in] flip Whether to flip vertically. - */ - void FlipHandleVertically( HandleType handleType, bool flip ); - - /** - * @brief Retrieves whether the handle is vertically flipped. - * - * @param[in] handleType The handle to query. - * - * @return @e ture if the handle is vertically flipped. - */ - bool IsHandleVerticallyFlipped( HandleType handleType ) const; - - /** * @brief Whether to flip the selection handles as soon as they are crossed. * * By default they flip when the handle is released. diff --git a/dali-toolkit/internal/text/layouts/layout-engine.cpp b/dali-toolkit/internal/text/layouts/layout-engine.cpp index ad513a8..9062b07 100644 --- a/dali-toolkit/internal/text/layouts/layout-engine.cpp +++ b/dali-toolkit/internal/text/layouts/layout-engine.cpp @@ -451,6 +451,7 @@ struct LayoutEngine::Impl const GlyphInfo& glyph = *glyphsBuffer; float penX = ( 0.f > glyph.xBearing ) ? -glyph.xBearing : 0.f; + penX += mCursorWidth; // Added to give some space to the cursor. for( GlyphIndex i = 0u; i < numberOfGlyphs; ++i ) { @@ -671,6 +672,7 @@ struct LayoutEngine::Impl const GlyphInfo& glyph = *( layoutParameters.glyphsBuffer + *( layoutParameters.charactersToGlyphsBuffer + characterVisualIndex ) ); float penX = ( 0.f > glyph.xBearing ) ? -glyph.xBearing : 0.f; + penX += mCursorWidth; // Added to give some space to the cursor. Vector2* glyphPositionsBuffer = glyphPositions.Begin(); @@ -766,12 +768,10 @@ struct LayoutEngine::Impl { if( isLastLine && !isRTL ) { - // Add the length of the white saces at the end of the line. lineLength += line.extraLength; if( lineLength > boxWidth ) { - // The line's length is longer than the box's width. - // Set the line's offset to 0 and nothing else to do. + lineLength = boxWidth; line.alignmentOffset = 0.f; break; } diff --git a/dali-toolkit/internal/text/rendering/atlas/text-atlas-renderer.cpp b/dali-toolkit/internal/text/rendering/atlas/text-atlas-renderer.cpp index 7e55978..5af46ef 100644 --- a/dali-toolkit/internal/text/rendering/atlas/text-atlas-renderer.cpp +++ b/dali-toolkit/internal/text/rendering/atlas/text-atlas-renderer.cpp @@ -238,7 +238,7 @@ struct AtlasRenderer::Impl : public ConnectionTracker currentUnderlinePosition = ceil( fabsf( fontMetrics.underlinePosition ) ); const float descender = ceil( fabsf( fontMetrics.descender ) ); - if( fabsf( underlineHeight ) < Math::MACHINE_EPSILON_1000 ) + if ( underlineHeight == ZERO ) { currentUnderlineThickness = fontMetrics.underlineThickness; @@ -258,7 +258,7 @@ struct AtlasRenderer::Impl : public ConnectionTracker { currentUnderlinePosition = descender; } - if( fabsf( currentUnderlinePosition ) < Math::MACHINE_EPSILON_1000 ) + if ( ZERO == currentUnderlinePosition ) { // Move offset down by one ( EFL behavior ) currentUnderlinePosition = ONE; @@ -358,7 +358,6 @@ struct AtlasRenderer::Impl : public ConnectionTracker // Now remove references for the old text RemoveText(); mTextCache.Swap( newTextCache ); - RemoveAllShadowRenderTasks(); if( thereAreUnderlinedGlyphs ) { @@ -437,7 +436,7 @@ struct AtlasRenderer::Impl : public ConnectionTracker Material material = mGlyphManager.GetMaterial( meshRecord.mAtlasId ); Dali::Renderer renderer = Dali::Renderer::New( quadGeometry, material ); - renderer.SetDepthIndex( CONTENT_DEPTH_INDEX + mDepth + 1 ); + renderer.SetDepthIndex( CONTENT_DEPTH_INDEX + mDepth ); Actor actor = Actor::New(); #if defined(DEBUG_ENABLED) actor.SetName( "Text renderable actor" ); @@ -724,7 +723,8 @@ struct AtlasRenderer::Impl : public ConnectionTracker Dali::Renderer renderer = Dali::Renderer::New( quadGeometry, material ); - renderer.SetDepthIndex( CONTENT_DEPTH_INDEX + mDepth ); + // Set depth index to -1.0 to make sure shadow is rendered first in 3D layers + renderer.SetDepthIndex( -1.0f ); Actor actor = Actor::New(); actor.AddRenderer( renderer ); actor.SetParentOrigin( ParentOrigin::CENTER ); // Keep all of the origins aligned @@ -760,37 +760,25 @@ struct AtlasRenderer::Impl : public ConnectionTracker subActor.SetColor( shadowColor ); // Create a render task to render the effect - RenderTask shadowTask = Stage::GetCurrent().GetRenderTaskList().CreateTask(); - shadowTask.SetTargetFrameBuffer( meshRecord.mBuffer ); - shadowTask.SetSourceActor( subActor ); - shadowTask.SetClearEnabled( true ); - shadowTask.SetClearColor( Vector4::ZERO ); - shadowTask.SetExclusive( true ); - shadowTask.SetRefreshRate( RenderTask::REFRESH_ONCE ); - shadowTask.FinishedSignal().Connect( this, &AtlasRenderer::Impl::RenderComplete ); - mShadowTasks.push_back( shadowTask ); + RenderTask task = Stage::GetCurrent().GetRenderTaskList().CreateTask(); + task.SetTargetFrameBuffer( meshRecord.mBuffer ); + task.SetSourceActor( subActor ); + task.SetClearEnabled( true ); + task.SetClearColor( Vector4::ZERO ); + task.SetExclusive( true ); + task.SetRefreshRate( RenderTask::REFRESH_ONCE ); + task.FinishedSignal().Connect( this, &AtlasRenderer::Impl::RenderComplete ); actor.Add( subActor ); return actor; } - void RemoveShadowRenderTask( RenderTask renderTask ) - { - if( renderTask ) - { - renderTask.FinishedSignal().Disconnect( this, &AtlasRenderer::Impl::RenderComplete ); - - // Guard to prevent accessing Stage after dali-core destruction - if( Stage::IsInstalled() ) - { - Stage::GetCurrent().GetRenderTaskList().RemoveTask( renderTask ); - } - renderTask.Reset(); - } - } - void RenderComplete( RenderTask& renderTask ) { + // Disconnect and remove this single shot render task + renderTask.FinishedSignal().Disconnect( this, &AtlasRenderer::Impl::RenderComplete ); + Stage::GetCurrent().GetRenderTaskList().RemoveTask( renderTask ); + // Get the actor used for render to buffer and remove it from the parent Actor renderActor = renderTask.GetSourceActor(); if ( renderActor ) @@ -801,23 +789,10 @@ struct AtlasRenderer::Impl : public ConnectionTracker parent.Remove( renderActor ); } } - - RemoveShadowRenderTask( renderTask ); - } - - void RemoveAllShadowRenderTasks() - { - for ( std::vector< RenderTask >::iterator shadowIterator = mShadowTasks.begin(); - shadowIterator != mShadowTasks.end(); ++shadowIterator ) - { - RemoveShadowRenderTask( *shadowIterator ); - } - mShadowTasks.clear(); } Actor mActor; ///< The actor parent which renders the text AtlasGlyphManager mGlyphManager; ///< Glyph Manager to handle upload and caching - std::vector< RenderTask > mShadowTasks; ///< Used to render shadows TextAbstraction::FontClient mFontClient; ///> The font client used to supply glyph information std::vector< MaxBlockSize > mBlockSizes; ///> Maximum size needed to contain a glyph in a block within a new atlas std::vector< uint32_t > mFace; ///> Face indices for a quad @@ -859,13 +834,6 @@ Actor AtlasRenderer::Render( Text::ViewInterface& view, int depth ) positions, glyphs, depth ); - - /* In the case where AddGlyphs does not create a renderable Actor for example when glyphs are all whitespace create a new Actor. */ - /* This renderable actor is used to position the text, other "decorations" can rely on there always being an Actor regardless of it is whitespace or regular text*/ - if ( !mImpl->mActor ) - { - mImpl->mActor = Actor::New(); - } } return mImpl->mActor; @@ -879,8 +847,6 @@ AtlasRenderer::AtlasRenderer() AtlasRenderer::~AtlasRenderer() { - mImpl->RemoveAllShadowRenderTasks(); - mImpl->RemoveText(); delete mImpl; } diff --git a/dali-toolkit/internal/text/text-controller-impl.cpp b/dali-toolkit/internal/text/text-controller-impl.cpp index 680df81..e533a3f 100644 --- a/dali-toolkit/internal/text/text-controller-impl.cpp +++ b/dali-toolkit/internal/text/text-controller-impl.cpp @@ -21,7 +21,6 @@ // EXTERNAL INCLUDES #include #include -#include // INTERNAL INCLUDES #include @@ -107,7 +106,6 @@ void GetGlyphsMetrics( GlyphIndex glyphIndex, EventData::EventData( DecoratorPtr decorator ) : mDecorator( decorator ), - mImfManager(), mPlaceholderTextActive(), mPlaceholderTextInactive(), mPlaceholderTextColor( 0.8f, 0.8f, 0.8f, 0.8f ), @@ -134,9 +132,7 @@ EventData::EventData( DecoratorPtr decorator ) mScrollAfterUpdatePosition( false ), mScrollAfterDelete( false ), mAllTextSelected( false ) -{ - mImfManager = ImfManager::Get(); -} +{} EventData::~EventData() {} @@ -204,81 +200,62 @@ bool Controller::Impl::ProcessInputEvents() if( mEventData->mUpdateCursorPosition ) { // Updates the cursor position and scrolls the text to make it visible. - CursorInfo cursorInfo; - GetCursorPosition( mEventData->mPrimaryCursorPosition, - cursorInfo ); + + UpdateCursorPosition(); if( mEventData->mScrollAfterUpdatePosition ) { - ScrollToMakePositionVisible( cursorInfo.primaryPosition ); + const Vector2& primaryCursorPosition = mEventData->mDecorator->GetPosition( PRIMARY_CURSOR ); + + ScrollToMakePositionVisible( primaryCursorPosition ); mEventData->mScrollAfterUpdatePosition = false; } - else if( mEventData->mScrollAfterDelete ) - { - ScrollTextToMatchCursor( cursorInfo ); - mEventData->mScrollAfterDelete = false; - } - - UpdateCursorPosition( cursorInfo ); mEventData->mDecoratorUpdated = true; mEventData->mUpdateCursorPosition = false; } + else if( mEventData->mScrollAfterDelete ) + { + ScrollTextToMatchCursor(); + mEventData->mDecoratorUpdated = true; + mEventData->mScrollAfterDelete = false; + } else { bool leftScroll = false; bool rightScroll = false; - CursorInfo leftHandleInfo; - CursorInfo rightHandleInfo; - if( mEventData->mUpdateLeftSelectionPosition ) { - GetCursorPosition( mEventData->mLeftSelectionPosition, - leftHandleInfo ); + UpdateSelectionHandle( LEFT_SELECTION_HANDLE ); if( mEventData->mScrollAfterUpdatePosition ) { - ScrollToMakePositionVisible( leftHandleInfo.primaryPosition ); + const Vector2& leftHandlePosition = mEventData->mDecorator->GetPosition( LEFT_SELECTION_HANDLE ); + + ScrollToMakePositionVisible( leftHandlePosition ); leftScroll = true; } + + SetPopupButtons(); + mEventData->mDecoratorUpdated = true; + mEventData->mUpdateLeftSelectionPosition = false; } if( mEventData->mUpdateRightSelectionPosition ) { - GetCursorPosition( mEventData->mRightSelectionPosition, - rightHandleInfo ); + UpdateSelectionHandle( RIGHT_SELECTION_HANDLE ); if( mEventData->mScrollAfterUpdatePosition ) { - ScrollToMakePositionVisible( rightHandleInfo.primaryPosition ); + const Vector2& rightHandlePosition = mEventData->mDecorator->GetPosition( RIGHT_SELECTION_HANDLE ); + + ScrollToMakePositionVisible( rightHandlePosition ); rightScroll = true; } - } - - if( mEventData->mUpdateLeftSelectionPosition ) - { - UpdateSelectionHandle( LEFT_SELECTION_HANDLE, - leftHandleInfo ); SetPopupButtons(); mEventData->mDecoratorUpdated = true; - } - - if( mEventData->mUpdateRightSelectionPosition ) - { - UpdateSelectionHandle( RIGHT_SELECTION_HANDLE, - rightHandleInfo ); - - SetPopupButtons(); - mEventData->mDecoratorUpdated = true; - } - - if( mEventData->mUpdateLeftSelectionPosition || mEventData->mUpdateRightSelectionPosition ) - { - RepositionSelectionHandles(); - - mEventData->mUpdateLeftSelectionPosition = false; mEventData->mUpdateRightSelectionPosition = false; } @@ -486,7 +463,7 @@ void Controller::Impl::GetDefaultFonts( Vector& fonts, Length numberOfC { if( mFontDefaults ) { - DALI_LOG_INFO( gLogFilter, Debug::General, "Controller::GetDefaultFonts font family(%s)\n", mFontDefaults->mFontDescription.family.c_str() ); + DALI_LOG_INFO( gLogFilter, Debug::Concise, "Controller::GetDefaultFonts font family(%s)\n", mFontDefaults->mFontDescription.family.c_str() ); FontRun fontRun; fontRun.characterRun.characterIndex = 0; fontRun.characterRun.numberOfCharacters = numberOfCharacters; @@ -561,8 +538,6 @@ void Controller::Impl::OnTapEvent( const Event& event ) if( 1u == tapCount ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); - if( IsShowingRealText() ) { const float xPosition = event.p2.mFloat - mEventData->mScrollPosition.x - mAlignmentOffset.x; @@ -581,13 +556,6 @@ void Controller::Impl::OnTapEvent( const Event& event ) mEventData->mUpdateCursorPosition = true; mEventData->mScrollAfterUpdatePosition = true; - - // Notify the cursor position to the imf manager. - if( mEventData->mImfManager ) - { - mEventData->mImfManager.SetCursorPosition( mEventData->mPrimaryCursorPosition ); - mEventData->mImfManager.NotifyCursorPosition(); - } } } } @@ -633,12 +601,8 @@ void Controller::Impl::OnPanEvent( const Event& event ) void Controller::Impl::OnLongPressEvent( const Event& event ) { - DALI_LOG_INFO( gLogFilter, Debug::General, "Controller::OnLongPressEvent\n" ); - if ( EventData::EDITING == mEventData->mState ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); - ChangeState ( EventData::EDITING_WITH_POPUP ); mEventData->mDecoratorUpdated = true; } @@ -682,6 +646,9 @@ void Controller::Impl::OnHandleEvent( const Event& event ) { mEventData->mLeftSelectionPosition = handleNewPosition; + RepositionSelectionHandles( mEventData->mLeftSelectionPosition, + mEventData->mRightSelectionPosition ); + mEventData->mUpdateLeftSelectionPosition = true; } } @@ -694,6 +661,9 @@ void Controller::Impl::OnHandleEvent( const Event& event ) { mEventData->mRightSelectionPosition = handleNewPosition; + RepositionSelectionHandles( mEventData->mLeftSelectionPosition, + mEventData->mRightSelectionPosition ); + mEventData->mUpdateRightSelectionPosition = true; } } @@ -715,10 +685,7 @@ void Controller::Impl::OnHandleEvent( const Event& event ) { mEventData->mUpdateCursorPosition = true; - if ( !IsClipboardEmpty() ) - { - ChangeState( EventData::EDITING_WITH_PASTE_POPUP ); // Moving grabhandle will show Paste Popup - } + ChangeState( EventData::EDITING_WITH_POPUP ); if( handleStopScrolling ) { @@ -738,6 +705,9 @@ void Controller::Impl::OnHandleEvent( const Event& event ) if( mEventData->mUpdateLeftSelectionPosition ) { mEventData->mLeftSelectionPosition = handlePosition; + + RepositionSelectionHandles( mEventData->mLeftSelectionPosition, + mEventData->mRightSelectionPosition ); } } } @@ -752,6 +722,8 @@ void Controller::Impl::OnHandleEvent( const Event& event ) if( mEventData->mUpdateRightSelectionPosition ) { mEventData->mRightSelectionPosition = handlePosition; + RepositionSelectionHandles( mEventData->mLeftSelectionPosition, + mEventData->mRightSelectionPosition ); } } } @@ -839,7 +811,8 @@ void Controller::Impl::OnHandleEvent( const Event& event ) if( mEventData->mUpdateLeftSelectionPosition || mEventData->mUpdateRightSelectionPosition ) { - RepositionSelectionHandles(); + RepositionSelectionHandles( mEventData->mLeftSelectionPosition, + mEventData->mRightSelectionPosition ); mEventData->mScrollAfterUpdatePosition = true; } @@ -858,27 +831,26 @@ void Controller::Impl::OnSelectEvent( const Event& event ) if( mEventData->mSelectionEnabled ) { - feedback_play_type( FEEDBACK_TYPE_SOUND, FEEDBACK_PATTERN_TAP ); - // The event.p2 and event.p3 are in decorator coords. Need to transforms to text coords. const float xPosition = event.p2.mFloat - mEventData->mScrollPosition.x - mAlignmentOffset.x; const float yPosition = event.p3.mFloat - mEventData->mScrollPosition.y - mAlignmentOffset.y; - // Calculates the logical position from the x,y coords. + const CharacterIndex leftPosition = mEventData->mLeftSelectionPosition; + const CharacterIndex rightPosition = mEventData->mRightSelectionPosition; + RepositionSelectionHandles( xPosition, yPosition ); - mEventData->mUpdateLeftSelectionPosition = true; - mEventData->mUpdateRightSelectionPosition = true; + mEventData->mUpdateLeftSelectionPosition = leftPosition != mEventData->mLeftSelectionPosition; + mEventData->mUpdateRightSelectionPosition = rightPosition != mEventData->mRightSelectionPosition; - mEventData->mScrollAfterUpdatePosition = ( mEventData->mLeftSelectionPosition != mEventData->mRightSelectionPosition ); + mEventData->mScrollAfterUpdatePosition = ( ( mEventData->mUpdateLeftSelectionPosition || mEventData->mUpdateRightSelectionPosition ) && + ( mEventData->mLeftSelectionPosition != mEventData->mRightSelectionPosition ) ); } } void Controller::Impl::OnSelectAllEvent() { - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "OnSelectAllEvent mEventData->mSelectionEnabled%s \n", mEventData->mSelectionEnabled?"true":"false"); - if( NULL == mEventData ) { // Nothing to do if there is no text. @@ -887,8 +859,8 @@ void Controller::Impl::OnSelectAllEvent() if( mEventData->mSelectionEnabled ) { - mEventData->mLeftSelectionPosition = 0u; - mEventData->mRightSelectionPosition = mLogicalModel->mText.Count(); + RepositionSelectionHandles( 0u, + mLogicalModel->mText.Count() ); mEventData->mScrollAfterUpdatePosition = true; mEventData->mUpdateLeftSelectionPosition = true; @@ -927,15 +899,9 @@ void Controller::Impl::RetrieveSelection( std::string& selectedText, bool delete Vector::Iterator first = currentText.Begin() + startOfSelectedText; Vector::Iterator last = first + lengthOfSelectedText; currentText.Erase( first, last ); - - // Scroll after delete. - mEventData->mPrimaryCursorPosition = handlesCrossed ? mEventData->mRightSelectionPosition : mEventData->mLeftSelectionPosition; - mEventData->mScrollAfterDelete = true; } - // Udpade the cursor position and the decorator. - // Scroll after the position is updated if is not scrolling after delete. - mEventData->mUpdateCursorPosition = true; - mEventData->mScrollAfterUpdatePosition = !mEventData->mScrollAfterDelete; + mEventData->mPrimaryCursorPosition = handlesCrossed ? mEventData->mRightSelectionPosition : mEventData->mLeftSelectionPosition; + mEventData->mScrollAfterDelete = true; mEventData->mDecoratorUpdated = true; } } @@ -978,11 +944,8 @@ void Controller::Impl::GetTextFromClipboard( unsigned int itemIndex, std::string } } -void Controller::Impl::RepositionSelectionHandles() +void Controller::Impl::RepositionSelectionHandles( CharacterIndex selectionStart, CharacterIndex selectionEnd ) { - CharacterIndex selectionStart = mEventData->mLeftSelectionPosition; - CharacterIndex selectionEnd = mEventData->mRightSelectionPosition; - if( selectionStart == selectionEnd ) { // Nothing to select if handles are in the same place. @@ -991,6 +954,9 @@ void Controller::Impl::RepositionSelectionHandles() mEventData->mDecorator->ClearHighlights(); + mEventData->mLeftSelectionPosition = selectionStart; + mEventData->mRightSelectionPosition = selectionEnd; + const GlyphIndex* const charactersToGlyphBuffer = mVisualModel->mCharactersToGlyph.Begin(); const Length* const glyphsPerCharacterBuffer = mVisualModel->mGlyphsPerCharacter.Begin(); const GlyphInfo* const glyphsBuffer = mVisualModel->mGlyphs.Begin(); @@ -1162,8 +1128,7 @@ void Controller::Impl::RepositionSelectionHandles( float visualX, float visualY return; } - mEventData->mLeftSelectionPosition = selectionStart; - mEventData->mRightSelectionPosition = selectionEnd; + RepositionSelectionHandles( selectionStart, selectionEnd ); } void Controller::Impl::SetPopupButtons() @@ -1178,7 +1143,7 @@ void Controller::Impl::SetPopupButtons() TextSelectionPopup::Buttons buttonsToShow = TextSelectionPopup::NONE; - if( EventData::SELECTING == mEventData->mState ) + if ( ( EventData::SELECTING == mEventData->mState ) || ( EventData::SELECTION_CHANGED == mEventData->mState ) ) { buttonsToShow = TextSelectionPopup::Buttons( TextSelectionPopup::CUT | TextSelectionPopup::COPY ); @@ -1193,7 +1158,7 @@ void Controller::Impl::SetPopupButtons() buttonsToShow = TextSelectionPopup::Buttons ( ( buttonsToShow | TextSelectionPopup::SELECT_ALL ) ); } } - else if ( EventData::EDITING_WITH_POPUP == mEventData->mState ) + else if ( EventData::EDITING_WITH_POPUP == mEventData->mState ) { if ( mLogicalModel->mText.Count() && !IsShowingPlaceholderText()) { @@ -1206,14 +1171,6 @@ void Controller::Impl::SetPopupButtons() buttonsToShow = TextSelectionPopup::Buttons ( ( buttonsToShow | TextSelectionPopup::CLIPBOARD ) ); } } - else if ( EventData::EDITING_WITH_PASTE_POPUP == mEventData->mState ) - { - if ( !IsClipboardEmpty() ) - { - buttonsToShow = TextSelectionPopup::Buttons ( ( buttonsToShow | TextSelectionPopup::PASTE ) ); - buttonsToShow = TextSelectionPopup::Buttons ( ( buttonsToShow | TextSelectionPopup::CLIPBOARD ) ); - } - } mEventData->mDecorator->SetEnabledPopupButtons( buttonsToShow ); } @@ -1226,8 +1183,6 @@ void Controller::Impl::ChangeState( EventData::State newState ) return; } - DALI_LOG_INFO( gLogFilter, Debug::General, "ChangeState state:%d newstate:%d\n", mEventData->mState, newState ); - if( mEventData->mState != newState ) { mEventData->mState = newState; @@ -1266,6 +1221,16 @@ void Controller::Impl::ChangeState( EventData::State newState ) } mEventData->mDecoratorUpdated = true; } + else if ( EventData::SELECTION_CHANGED == mEventData->mState ) + { + if( mEventData->mGrabHandlePopupEnabled ) + { + SetPopupButtons(); + mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_NONE ); + mEventData->mDecorator->SetPopupActive( true ); + } + mEventData->mDecoratorUpdated = true; + } else if( EventData::EDITING == mEventData->mState ) { mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_PRIMARY ); @@ -1286,8 +1251,6 @@ void Controller::Impl::ChangeState( EventData::State newState ) } else if( EventData::EDITING_WITH_POPUP == mEventData->mState ) { - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "EDITING_WITH_POPUP \n", newState ); - mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_PRIMARY ); if( mEventData->mCursorBlinkEnabled ) { @@ -1312,8 +1275,6 @@ void Controller::Impl::ChangeState( EventData::State newState ) } else if( EventData::EDITING_WITH_GRAB_HANDLE == mEventData->mState ) { - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "EDITING_WITH_GRAB_HANDLE \n", newState ); - mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_PRIMARY ); if( mEventData->mCursorBlinkEnabled ) { @@ -1345,8 +1306,6 @@ void Controller::Impl::ChangeState( EventData::State newState ) } else if ( EventData::GRAB_HANDLE_PANNING == mEventData->mState ) { - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "GRAB_HANDLE_PANNING \n", newState ); - mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_PRIMARY ); if( mEventData->mCursorBlinkEnabled ) { @@ -1361,28 +1320,6 @@ void Controller::Impl::ChangeState( EventData::State newState ) } mEventData->mDecoratorUpdated = true; } - else if ( EventData::EDITING_WITH_PASTE_POPUP == mEventData->mState ) - { - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "EDITING_WITH_PASTE_POPUP \n", newState ); - - mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_PRIMARY ); - if( mEventData->mCursorBlinkEnabled ) - { - mEventData->mDecorator->StartCursorBlink(); - } - - mEventData->mDecorator->SetHandleActive( GRAB_HANDLE, true ); - mEventData->mDecorator->SetHandleActive( LEFT_SELECTION_HANDLE, false ); - mEventData->mDecorator->SetHandleActive( RIGHT_SELECTION_HANDLE, false ); - - if( mEventData->mGrabHandlePopupEnabled ) - { - SetPopupButtons(); - mEventData->mDecorator->SetPopupActive( true ); - } - HideClipboard(); - mEventData->mDecoratorUpdated = true; - } } } @@ -1438,22 +1375,26 @@ void Controller::Impl::FindSelectionIndices( float visualX, float visualY, Chara startIndex = hitCharacter; endIndex = hitCharacter; - bool isHitCharacterWhitespace = TextAbstraction::IsWhiteSpace( mLogicalModel->mText[hitCharacter] ); - // Find the start and end of the text - for( startIndex = hitCharacter; startIndex > 0; --startIndex ) + if( !TextAbstraction::IsWhiteSpace( mLogicalModel->mText[hitCharacter] ) ) { - if( isHitCharacterWhitespace != TextAbstraction::IsWhiteSpace( mLogicalModel->mText[ startIndex-1 ] ) ) + // Find the start and end of the text + for( startIndex = hitCharacter; startIndex > 0; --startIndex ) { - break; + Character charCode = mLogicalModel->mText[ startIndex-1 ]; + if( TextAbstraction::IsWhiteSpace( charCode ) ) + { + break; + } } - } - const CharacterIndex pastTheEnd = mLogicalModel->mText.Count(); - for( endIndex = hitCharacter + 1u; endIndex < pastTheEnd; ++endIndex ) - { - if( isHitCharacterWhitespace != TextAbstraction::IsWhiteSpace( mLogicalModel->mText[ endIndex ] ) ) + const CharacterIndex pastTheEnd = mLogicalModel->mText.Count(); + for( endIndex = hitCharacter + 1u; endIndex < pastTheEnd; ++endIndex ) { - break; + Character charCode = mLogicalModel->mText[ endIndex ]; + if( TextAbstraction::IsWhiteSpace( charCode ) ) + { + break; + } } } } @@ -1496,6 +1437,7 @@ CharacterIndex Controller::Impl::GetClosestCursorIndex( float visualX, // Get the glyphs per character table. const Length* const glyphsPerCharacterBuffer = mVisualModel->mGlyphsPerCharacter.Begin(); + const Length* const charactersPerGlyphBuffer = mVisualModel->mCharactersPerGlyph.Begin(); // If the vector is void, there is no right to left characters. const bool hasRightToLeftCharacters = NULL != visualToLogicalBuffer; @@ -1509,7 +1451,6 @@ CharacterIndex Controller::Impl::GetClosestCursorIndex( float visualX, // Traverses glyphs in visual order. To do that use the visual to logical conversion table. CharacterIndex visualIndex = startCharacter; - Length numberOfCharacters = 0u; for( ; !matched && ( visualIndex < endCharacter ); ++visualIndex ) { // The character in logical order. @@ -1518,59 +1459,44 @@ CharacterIndex Controller::Impl::GetClosestCursorIndex( float visualX, // Get the script of the character. const Script script = mLogicalModel->GetScript( characterLogicalOrderIndex ); + // The first glyph for that character in logical order. + const GlyphIndex glyphLogicalOrderIndex = *( charactersToGlyphBuffer + characterLogicalOrderIndex ); // The number of glyphs for that character const Length numberOfGlyphs = *( glyphsPerCharacterBuffer + characterLogicalOrderIndex ); - ++numberOfCharacters; + // Get the metrics for the group of glyphs. + GlyphMetrics glyphMetrics; + GetGlyphsMetrics( glyphLogicalOrderIndex, + numberOfGlyphs, + glyphMetrics, + mVisualModel, + mMetrics ); - if( 0u != numberOfGlyphs ) - { - // Get the first character/glyph of the group of glyphs. - const CharacterIndex firstVisualCharacterIndex = 1u + visualIndex - numberOfCharacters; - const CharacterIndex firstLogicalCharacterIndex = hasRightToLeftCharacters ? *( visualToLogicalBuffer + firstVisualCharacterIndex ) : firstVisualCharacterIndex; - const GlyphIndex firstLogicalGlyphIndex = *( charactersToGlyphBuffer + firstLogicalCharacterIndex ); - - // Get the metrics for the group of glyphs. - GlyphMetrics glyphMetrics; - GetGlyphsMetrics( firstLogicalGlyphIndex, - numberOfGlyphs, - glyphMetrics, - mVisualModel, - mMetrics ); - - // Get the position of the first glyph. - const Vector2& position = *( positionsBuffer + firstLogicalGlyphIndex ); - - // Whether the glyph can be split, like Latin ligatures fi, ff or Arabic ï»». - const bool isInterglyphIndex = ( numberOfCharacters > numberOfGlyphs ) && HasLigatureMustBreak( script ); - const Length numberOfBlocks = isInterglyphIndex ? numberOfCharacters : 1u; - const float glyphAdvance = glyphMetrics.advance / static_cast( numberOfBlocks ); + const Vector2& position = *( positionsBuffer + glyphLogicalOrderIndex ); - GlyphIndex index = 0u; - for( ; !matched && ( index < numberOfBlocks ); ++index ) - { - // Find the mid-point of the area containing the glyph - const float glyphCenter = -glyphMetrics.xBearing + position.x + ( static_cast( index ) + 0.5f ) * glyphAdvance; + // Prevents to jump the whole Latin ligatures like fi, ff, or Arabic ï»»... + const Length numberOfCharactersInLigature = HasLigatureMustBreak( script ) ? *( charactersPerGlyphBuffer + glyphLogicalOrderIndex ) : 1u; + const float glyphAdvance = glyphMetrics.advance / static_cast( numberOfCharactersInLigature ); - if( visualX < glyphCenter ) - { - matched = true; - break; - } - } + for( GlyphIndex index = 0u; !matched && ( index < numberOfCharactersInLigature ); ++index ) + { + // Find the mid-point of the area containing the glyph + const float glyphCenter = -glyphMetrics.xBearing + position.x + ( static_cast( index ) + 0.5f ) * glyphAdvance; - if( matched ) + if( visualX < glyphCenter ) { - visualIndex = firstVisualCharacterIndex + index; + visualIndex += index; + matched = true; break; } - - numberOfCharacters = 0u; } + if( matched ) + { + break; + } } - // Return the logical position of the cursor in characters. if( !matched ) @@ -1591,64 +1517,23 @@ void Controller::Impl::GetCursorPosition( CharacterIndex logical, { // TODO: Check for multiline with \n, etc... - const Length numberOfCharacters = mLogicalModel->mText.Count(); - if( !IsShowingRealText() ) - { - // Do not want to use the place-holder text to set the cursor position. - - // Use the line's height of the font's family set to set the cursor's size. - // If there is no font's family set, use the default font. - // Use the current alignment to place the cursor at the beginning, center or end of the box. + // Check if the logical position is the first or the last one of the text. + const bool isFirstPosition = 0u == logical; + const bool isLastPosition = mLogicalModel->mText.Count() == logical; + if( isFirstPosition && isLastPosition ) + { + // There is zero characters. Get the default font's line height. cursorInfo.lineHeight = GetDefaultFontLineHeight(); cursorInfo.primaryCursorHeight = cursorInfo.lineHeight; - switch( mLayoutEngine.GetHorizontalAlignment() ) - { - case LayoutEngine::HORIZONTAL_ALIGN_BEGIN: - { - cursorInfo.primaryPosition.x = 0.f; - break; - } - case LayoutEngine::HORIZONTAL_ALIGN_CENTER: - { - cursorInfo.primaryPosition.x = floorf( 0.5f * mVisualModel->mControlSize.width ); - break; - } - case LayoutEngine::HORIZONTAL_ALIGN_END: - { - cursorInfo.primaryPosition.x = mVisualModel->mControlSize.width - mEventData->mDecorator->GetCursorWidth(); - break; - } - } - - switch( mLayoutEngine.GetVerticalAlignment() ) - { - case LayoutEngine::VERTICAL_ALIGN_TOP: - { - cursorInfo.primaryPosition.y = 0.f; - break; - } - case LayoutEngine::VERTICAL_ALIGN_CENTER: - { - cursorInfo.primaryPosition.y = floorf( 0.5f * ( mVisualModel->mControlSize.height - cursorInfo.lineHeight ) ); - break; - } - case LayoutEngine::VERTICAL_ALIGN_BOTTOM: - { - cursorInfo.primaryPosition.y = mVisualModel->mControlSize.height - cursorInfo.lineHeight; - break; - } - } + cursorInfo.primaryPosition.x = mEventData->mDecorator->GetCursorWidth(); + cursorInfo.primaryPosition.y = 0.f; // Nothing else to do. return; } - // Check if the logical position is the first or the last one of the text. - const bool isFirstPosition = 0u == logical; - const bool isLastPosition = numberOfCharacters == logical; - // 'logical' is the logical 'cursor' index. // Get the next and current logical 'character' index. const CharacterIndex nextCharacterIndex = logical; @@ -1868,7 +1753,7 @@ CharacterIndex Controller::Impl::CalculateNewCursorIndex( CharacterIndex index ) return cursorIndex; } -void Controller::Impl::UpdateCursorPosition( const CursorInfo& cursorInfo ) +void Controller::Impl::UpdateCursorPosition() { DALI_LOG_INFO( gLogFilter, Debug::Verbose, "-->Controller::UpdateCursorPosition %p\n", this ); if( NULL == mEventData ) @@ -1878,55 +1763,121 @@ void Controller::Impl::UpdateCursorPosition( const CursorInfo& cursorInfo ) return; } - const Vector2 offset = mEventData->mScrollPosition + ( IsShowingRealText() ? mAlignmentOffset : Vector2::ZERO ); - const Vector2 cursorPosition = cursorInfo.primaryPosition + offset; + if( IsShowingPlaceholderText() || ( 0u == mLogicalModel->mText.Count() ) ) + { + // Do not want to use the place-holder text to set the cursor position. - // Sets the cursor position. - mEventData->mDecorator->SetPosition( PRIMARY_CURSOR, - cursorPosition.x, - cursorPosition.y, - cursorInfo.primaryCursorHeight, - cursorInfo.lineHeight ); - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "Primary cursor position: %f,%f\n", cursorPosition.x, cursorPosition.y ); + // Use the line's height of the font's family set to set the cursor's size. + // If there is no font's family set, use the default font. + // Use the current alignment to place the cursor at the beginning, center or end of the box. - // Sets the grab handle position. - mEventData->mDecorator->SetPosition( GRAB_HANDLE, - cursorPosition.x, - cursorPosition.y, - cursorInfo.lineHeight ); + float lineHeight = 0.f; - if( cursorInfo.isSecondaryCursor ) + FontId defaultFontId = 0u; + if( NULL == mFontDefaults ) + { + TextAbstraction::FontDescription fontDescription; + defaultFontId = mFontClient.GetFontId( fontDescription ); + } + else + { + defaultFontId = mFontDefaults->GetFontId( mFontClient ); + } + + Text::FontMetrics fontMetrics; + mMetrics->GetFontMetrics( defaultFontId, fontMetrics ); + + lineHeight = fontMetrics.ascender - fontMetrics.descender; + + + Vector2 cursorPosition; + + switch( mLayoutEngine.GetHorizontalAlignment() ) + { + case LayoutEngine::HORIZONTAL_ALIGN_BEGIN: + { + cursorPosition.x = mEventData->mDecorator->GetCursorWidth(); + break; + } + case LayoutEngine::HORIZONTAL_ALIGN_CENTER: + { + cursorPosition.x = floor( 0.5f * mVisualModel->mControlSize.width ); + break; + } + case LayoutEngine::HORIZONTAL_ALIGN_END: + { + cursorPosition.x = mVisualModel->mControlSize.width; + break; + } + } + + switch( mLayoutEngine.GetVerticalAlignment() ) + { + case LayoutEngine::VERTICAL_ALIGN_TOP: + { + cursorPosition.y = 0.f; + break; + } + case LayoutEngine::VERTICAL_ALIGN_CENTER: + { + cursorPosition.y = floorf( 0.5f * ( mVisualModel->mControlSize.height - lineHeight ) ); + break; + } + case LayoutEngine::VERTICAL_ALIGN_BOTTOM: + { + cursorPosition.y = mVisualModel->mControlSize.height - lineHeight; + break; + } + } + + mEventData->mDecorator->SetPosition( PRIMARY_CURSOR, + cursorPosition.x, + cursorPosition.y, + lineHeight, + lineHeight ); + } + else { - mEventData->mDecorator->SetPosition( SECONDARY_CURSOR, - cursorInfo.secondaryPosition.x + offset.x, - cursorInfo.secondaryPosition.y + offset.y, - cursorInfo.secondaryCursorHeight, + CursorInfo cursorInfo; + GetCursorPosition( mEventData->mPrimaryCursorPosition, + cursorInfo ); + + const Vector2 offset = mEventData->mScrollPosition + mAlignmentOffset; + const Vector2 cursorPosition = cursorInfo.primaryPosition + offset; + + // Sets the cursor position. + mEventData->mDecorator->SetPosition( PRIMARY_CURSOR, + cursorPosition.x, + cursorPosition.y, + cursorInfo.primaryCursorHeight, + cursorInfo.lineHeight ); + DALI_LOG_INFO( gLogFilter, Debug::Verbose, "Primary cursor position: %f,%f\n", cursorPosition.x, cursorPosition.y ); + + // Sets the grab handle position. + mEventData->mDecorator->SetPosition( GRAB_HANDLE, + cursorPosition.x, + cursorPosition.y, cursorInfo.lineHeight ); - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "Secondary cursor position: %f,%f\n", cursorInfo.secondaryPosition.x + offset.x, cursorInfo.secondaryPosition.y + offset.y ); - } - // Set which cursors are active according the state. - if( EventData::IsEditingState( mEventData->mState ) || ( EventData::GRAB_HANDLE_PANNING == mEventData->mState ) ) - { if( cursorInfo.isSecondaryCursor ) { mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_BOTH ); + mEventData->mDecorator->SetPosition( SECONDARY_CURSOR, + cursorInfo.secondaryPosition.x + offset.x, + cursorInfo.secondaryPosition.y + offset.y, + cursorInfo.secondaryCursorHeight, + cursorInfo.lineHeight ); + DALI_LOG_INFO( gLogFilter, Debug::Verbose, "Secondary cursor position: %f,%f\n", cursorInfo.secondaryPosition.x + offset.x, cursorInfo.secondaryPosition.y + offset.y ); } else { mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_PRIMARY ); } } - else - { - mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_NONE ); - } - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "<--Controller::UpdateCursorPosition\n" ); } -void Controller::Impl::UpdateSelectionHandle( HandleType handleType, - const CursorInfo& cursorInfo ) +void Controller::Impl::UpdateSelectionHandle( HandleType handleType ) { if( ( LEFT_SELECTION_HANDLE != handleType ) && ( RIGHT_SELECTION_HANDLE != handleType ) ) @@ -1934,9 +1885,17 @@ void Controller::Impl::UpdateSelectionHandle( HandleType handleType, return; } - const Vector2 cursorPosition = cursorInfo.primaryPosition + mEventData->mScrollPosition + mAlignmentOffset; + const bool leftSelectionHandle = LEFT_SELECTION_HANDLE == handleType; + const CharacterIndex index = leftSelectionHandle ? mEventData->mLeftSelectionPosition : mEventData->mRightSelectionPosition; + + CursorInfo cursorInfo; + GetCursorPosition( index, + cursorInfo ); + + const Vector2 offset = mEventData->mScrollPosition + mAlignmentOffset; + const Vector2 cursorPosition = cursorInfo.primaryPosition + offset; - // Sets the handle's position. + // Sets the grab handle position. mEventData->mDecorator->SetPosition( handleType, cursorPosition.x, cursorPosition.y, @@ -1951,7 +1910,6 @@ void Controller::Impl::UpdateSelectionHandle( HandleType handleType, void Controller::Impl::ClampHorizontalScroll( const Vector2& actualSize ) { // Clamp between -space & 0 (and the text alignment). - if( actualSize.width > mVisualModel->mControlSize.width ) { const float space = ( actualSize.width - mVisualModel->mControlSize.width ) + mAlignmentOffset.x; @@ -1985,33 +1943,89 @@ void Controller::Impl::ClampVerticalScroll( const Vector2& actualSize ) void Controller::Impl::ScrollToMakePositionVisible( const Vector2& position ) { - // position is in actor's coords. - const float positionEnd = position.x + ( mEventData->mDecorator ? mEventData->mDecorator->GetCursorWidth() : 0.f ); - - // Transform the position to decorator coords. - const float offset = mEventData->mScrollPosition.x + mAlignmentOffset.x; - const float decoratorPositionBegin = position.x + offset; - const float decoratorPositionEnd = positionEnd + offset; - - if( decoratorPositionBegin < 0.f ) + Vector2 offset; + bool updateDecorator = false; + if( position.x < 0.f ) { - mEventData->mScrollPosition.x = -position.x - mAlignmentOffset.x; + offset.x = -position.x; + mEventData->mScrollPosition.x += offset.x; + updateDecorator = true; } - else if( decoratorPositionEnd > mVisualModel->mControlSize.width ) + else if( position.x > mVisualModel->mControlSize.width ) { - mEventData->mScrollPosition.x = mVisualModel->mControlSize.width - positionEnd - mAlignmentOffset.x; + offset.x = mVisualModel->mControlSize.width - position.x; + mEventData->mScrollPosition.x += offset.x; + updateDecorator = true; } + + if( updateDecorator && mEventData->mDecorator ) + { + mEventData->mDecorator->UpdatePositions( offset ); + } + + // TODO : calculate the vertical scroll. } -void Controller::Impl::ScrollTextToMatchCursor( const CursorInfo& cursorInfo ) +void Controller::Impl::ScrollTextToMatchCursor() { // Get the current cursor position in decorator coords. const Vector2& currentCursorPosition = mEventData->mDecorator->GetPosition( PRIMARY_CURSOR ); + // Calculate the new cursor position. + CursorInfo cursorInfo; + GetCursorPosition( mEventData->mPrimaryCursorPosition, + cursorInfo ); + // Calculate the offset to match the cursor position before the character was deleted. mEventData->mScrollPosition.x = currentCursorPosition.x - cursorInfo.primaryPosition.x - mAlignmentOffset.x; ClampHorizontalScroll( mVisualModel->GetActualSize() ); + + const Vector2 offset = mEventData->mScrollPosition + mAlignmentOffset; + const Vector2 cursorPosition = cursorInfo.primaryPosition + offset; + + // Sets the cursor position. + mEventData->mDecorator->SetPosition( PRIMARY_CURSOR, + cursorPosition.x, + cursorPosition.y, + cursorInfo.primaryCursorHeight, + cursorInfo.lineHeight ); + + // Sets the grab handle position. + mEventData->mDecorator->SetPosition( GRAB_HANDLE, + cursorPosition.x, + cursorPosition.y, + cursorInfo.lineHeight ); + + if( cursorInfo.isSecondaryCursor ) + { + mEventData->mDecorator->SetPosition( SECONDARY_CURSOR, + cursorInfo.secondaryPosition.x + offset.x, + cursorInfo.secondaryPosition.y + offset.y, + cursorInfo.secondaryCursorHeight, + cursorInfo.lineHeight ); + DALI_LOG_INFO( gLogFilter, Debug::Verbose, "Secondary cursor position: %f,%f\n", cursorInfo.secondaryPosition.x + offset.x, cursorInfo.secondaryPosition.y + offset.y ); + } + + // Set which cursors are active according the state. + if( ( EventData::EDITING == mEventData->mState ) || + ( EventData::EDITING_WITH_POPUP == mEventData->mState ) || + ( EventData::EDITING_WITH_GRAB_HANDLE == mEventData->mState ) || + ( EventData::GRAB_HANDLE_PANNING == mEventData->mState ) ) + { + if( cursorInfo.isSecondaryCursor ) + { + mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_BOTH ); + } + else + { + mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_PRIMARY ); + } + } + else + { + mEventData->mDecorator->SetActiveCursor( ACTIVE_CURSOR_NONE ); + } } void Controller::Impl::RequestRelayout() diff --git a/dali-toolkit/internal/text/text-controller-impl.h b/dali-toolkit/internal/text/text-controller-impl.h index 77f7f39..218f79b 100644 --- a/dali-toolkit/internal/text/text-controller-impl.h +++ b/dali-toolkit/internal/text/text-controller-impl.h @@ -105,10 +105,10 @@ struct EventData INACTIVE, INTERRUPTED, SELECTING, + SELECTION_CHANGED, EDITING, EDITING_WITH_POPUP, EDITING_WITH_GRAB_HANDLE, - EDITING_WITH_PASTE_POPUP, GRAB_HANDLE_PANNING, SELECTION_HANDLE_PANNING }; @@ -117,16 +117,10 @@ struct EventData ~EventData(); - static bool IsEditingState( State stateToCheck ) - { - return ( stateToCheck == EDITING || stateToCheck == EDITING_WITH_POPUP || stateToCheck == EDITING_WITH_GRAB_HANDLE || stateToCheck == EDITING_WITH_PASTE_POPUP ); - } - - DecoratorPtr mDecorator; ///< Pointer to the decorator. - ImfManager mImfManager; ///< The Input Method Framework Manager. - std::string mPlaceholderTextActive; ///< The text to display when the TextField is empty with key-input focus. - std::string mPlaceholderTextInactive; ///< The text to display when the TextField is empty and inactive. - Vector4 mPlaceholderTextColor; ///< The in/active placeholder text color. + DecoratorPtr mDecorator; ///< Pointer to the decorator + std::string mPlaceholderTextActive; ///< The text to display when the TextField is empty with key-input focus + std::string mPlaceholderTextInactive; ///< The text to display when the TextField is empty and inactive + Vector4 mPlaceholderTextColor; ///< The in/active placeholder text color /** * This is used to delay handling events until after the model has been updated. @@ -187,8 +181,8 @@ struct FontDefaults mFontId(0u) { // Initially use the default platform font - TextAbstraction::FontClient fontClient = TextAbstraction::FontClient::Get(); - fontClient.GetDefaultPlatformFontDescription( mFontDescription ); +// TextAbstraction::FontClient fontClient = TextAbstraction::FontClient::Get(); +// fontClient.GetDefaultPlatformFontDescription( mFontDescription ); } FontId GetFontId( TextAbstraction::FontClient& fontClient ) @@ -340,9 +334,10 @@ struct Controller::Impl if( mEventData ) { // Reset incase we are in a pre-edit state. - if( mEventData->mImfManager ) + ImfManager imfManager = ImfManager::Get(); + if ( imfManager ) { - mEventData->mImfManager.Reset(); // Will trigger a message ( commit, get surrounding ) + imfManager.Reset(); // Will trigger a commit message } ClearPreEditFlag(); @@ -396,7 +391,7 @@ struct Controller::Impl void GetTextFromClipboard( unsigned int itemIndex, std::string& retreivedString ); - void RepositionSelectionHandles(); + void RepositionSelectionHandles( CharacterIndex selectionStart, CharacterIndex selectionEnd ); void RepositionSelectionHandles( float visualX, float visualY ); void SetPopupButtons(); @@ -444,23 +439,18 @@ struct Controller::Impl /** * @brief Updates the cursor position. * - * Sets the cursor's position into the decorator. It transforms the cursor's position into decorator's coords. + * Retrieves the x,y position of the cursor logical position and sets it into the decorator. * It sets the position of the secondary cursor if it's a valid one. * Sets which cursors are active. - * - * @param[in] cursorInfo Contains the selection handle position in Actor's coords. - * */ - void UpdateCursorPosition( const CursorInfo& cursorInfo ); + void UpdateCursorPosition(); /** - * @brief Updates the position of the given selection handle. It transforms the handle's position into decorator's coords. + * @brief Updates the position of the given selection handle. * * @param[in] handleType One of the selection handles. - * @param[in] cursorInfo Contains the selection handle position in Actor's coords. */ - void UpdateSelectionHandle( HandleType handleType, - const CursorInfo& cursorInfo ); + void UpdateSelectionHandle( HandleType handleType ); /** * @biref Clamps the horizontal scrolling to get the control always filled with text. @@ -493,7 +483,7 @@ struct Controller::Impl * * This method is called after deleting text. */ - void ScrollTextToMatchCursor( const CursorInfo& cursorInfo); + void ScrollTextToMatchCursor(); ControlInterface& mControlInterface; ///< Reference to the text controller. LogicalModelPtr mLogicalModel; ///< Pointer to the logical model. @@ -513,7 +503,6 @@ struct Controller::Impl bool mRecalculateNaturalSize:1; ///< Whether the natural size needs to be recalculated. bool mUserDefinedFontFamily:1; ///< Whether the Font family was set by the user instead of being left as sytem default. - }; } // namespace Text diff --git a/dali-toolkit/internal/text/text-controller.cpp b/dali-toolkit/internal/text/text-controller.cpp index 4ed0231..7ec540b 100644 --- a/dali-toolkit/internal/text/text-controller.cpp +++ b/dali-toolkit/internal/text/text-controller.cpp @@ -89,9 +89,9 @@ void Controller::SetText( const std::string& text ) { // If popup shown then hide it by switching to Editing state if( ( EventData::SELECTING == mImpl->mEventData->mState ) || + ( EventData::SELECTION_CHANGED == mImpl->mEventData->mState ) || ( EventData::EDITING_WITH_POPUP == mImpl->mEventData->mState ) || - ( EventData::EDITING_WITH_GRAB_HANDLE == mImpl->mEventData->mState ) || - ( EventData::EDITING_WITH_PASTE_POPUP == mImpl->mEventData->mState ) ) + ( EventData::EDITING_WITH_GRAB_HANDLE == mImpl->mEventData->mState ) ) { mImpl->ChangeState( EventData::EDITING ); } @@ -453,12 +453,12 @@ bool Controller::RemoveText( int cursorOffset, int numberOfChars ) cursorIndex = oldCursorIndex + cursorOffset; } - if( ( cursorIndex + numberOfChars ) > currentText.Count() ) + if( (cursorIndex + numberOfChars) > currentText.Count() ) { numberOfChars = currentText.Count() - cursorIndex; } - if( ( cursorIndex + numberOfChars ) <= currentText.Count() ) + if( (cursorIndex + numberOfChars) <= currentText.Count() ) { Vector::Iterator first = currentText.Begin() + cursorIndex; Vector::Iterator last = first + numberOfChars; @@ -667,7 +667,7 @@ float Controller::GetHeightForWidth( float width ) ProcessModifyEvents(); Size layoutSize; - if( fabsf( width - mImpl->mVisualModel->mControlSize.width ) > Math::MACHINE_EPSILON_1000 ) + if( width != mImpl->mVisualModel->mControlSize.width ) { // Operations that can be done only once until the text changes. const OperationsMask onlyOnceOperations = static_cast( CONVERT_TO_UTF32 | @@ -724,9 +724,7 @@ bool Controller::Relayout( const Size& size ) return glyphsRemoved; } - const bool newSize = ( size != mImpl->mVisualModel->mControlSize ); - - if( newSize ) + if( size != mImpl->mVisualModel->mControlSize ) { DALI_LOG_INFO( gLogFilter, Debug::Verbose, "new size (previous size %f,%f)\n", mImpl->mVisualModel->mControlSize.width, mImpl->mVisualModel->mControlSize.height ); @@ -752,9 +750,9 @@ bool Controller::Relayout( const Size& size ) // Do not re-do any operation until something changes. mImpl->mOperationsPending = NO_OPERATION; - // Keep the current offset and alignment as it will be used to update the decorator's positions (if the size changes). + // Keep the current offset and alignment as it will be used to update the decorator's positions. Vector2 offset; - if( newSize && mImpl->mEventData ) + if( mImpl->mEventData ) { offset = mImpl->mAlignmentOffset + mImpl->mEventData->mScrollPosition; } @@ -764,14 +762,11 @@ bool Controller::Relayout( const Size& size ) if( mImpl->mEventData ) { - if( newSize ) - { - // If there is a new size, the scroll position needs to be clamped. - mImpl->ClampHorizontalScroll( layoutSize ); + // If there is a nex size, the scroll position needs to be clamped. + mImpl->ClampHorizontalScroll( layoutSize ); - // Update the decorator's positions is needed if there is a new size. - mImpl->mEventData->mDecorator->UpdatePositions( mImpl->mAlignmentOffset + mImpl->mEventData->mScrollPosition - offset ); - } + // Update the decorator's positions. + mImpl->mEventData->mDecorator->UpdatePositions( mImpl->mAlignmentOffset + mImpl->mEventData->mScrollPosition - offset ); // Move the cursor, grab handle etc. updated = mImpl->ProcessInputEvents() || updated; @@ -843,7 +838,9 @@ void Controller::ResetCursorPosition( CharacterIndex cursorIndex ) mImpl->mEventData->mPrimaryCursorPosition = cursorIndex; // Update the cursor if it's in editing mode. - if ( EventData::IsEditingState( mImpl->mEventData->mState ) ) + if( ( EventData::EDITING == mImpl->mEventData->mState ) || + ( EventData::EDITING_WITH_POPUP == mImpl->mEventData->mState ) || + ( EventData::EDITING_WITH_GRAB_HANDLE == mImpl->mEventData->mState ) ) { mImpl->mEventData->mUpdateCursorPosition = true; } @@ -896,7 +893,9 @@ void Controller::TextInsertedEvent() REORDER ); // Queue a cursor reposition event; this must wait until after DoRelayout() - if ( EventData::IsEditingState( mImpl->mEventData->mState ) ) + if( ( EventData::EDITING == mImpl->mEventData->mState ) || + ( EventData::EDITING_WITH_POPUP == mImpl->mEventData->mState ) || + ( EventData::EDITING_WITH_GRAB_HANDLE == mImpl->mEventData->mState ) ) { mImpl->mEventData->mUpdateCursorPosition = true; mImpl->mEventData->mScrollAfterUpdatePosition = true; @@ -922,8 +921,11 @@ void Controller::TextDeletedEvent() REORDER ); // Queue a cursor reposition event; this must wait until after DoRelayout() - mImpl->mEventData->mUpdateCursorPosition = true; - if( 0u != mImpl->mLogicalModel->mText.Count() ) + if( 0u == mImpl->mLogicalModel->mText.Count() ) + { + mImpl->mEventData->mUpdateCursorPosition = true; + } + else { mImpl->mEventData->mScrollAfterDelete = true; } @@ -1176,7 +1178,8 @@ void Controller::CalculateTextAlignment( const Size& size ) } case LayoutEngine::HORIZONTAL_ALIGN_CENTER: { - mImpl->mAlignmentOffset.x = floorf( 0.5f * ( size.width - actualSize.width ) ); // try to avoid pixel alignment. + const int intOffset = static_cast( 0.5f * ( size.width - actualSize.width ) ); // try to avoid pixel alignment. + mImpl->mAlignmentOffset.x = static_cast( intOffset ); break; } case LayoutEngine::HORIZONTAL_ALIGN_END: @@ -1196,7 +1199,8 @@ void Controller::CalculateTextAlignment( const Size& size ) } case LayoutEngine::VERTICAL_ALIGN_CENTER: { - mImpl->mAlignmentOffset.y = floorf( 0.5f * ( size.height - actualSize.height ) ); // try to avoid pixel alignment. + const int intOffset = static_cast( 0.5f * ( size.height - actualSize.height ) ); // try to avoid pixel alignment. + mImpl->mAlignmentOffset.y = static_cast( intOffset ); break; } case LayoutEngine::VERTICAL_ALIGN_BOTTOM: @@ -1249,7 +1253,6 @@ void Controller::KeyboardFocusLostEvent() if ( EventData::INTERRUPTED != mImpl->mEventData->mState ) { mImpl->ChangeState( EventData::INACTIVE ); - mImpl->mEventData->mUpdateCursorPosition = false; if( !mImpl->IsShowingRealText() ) { @@ -1481,7 +1484,8 @@ bool Controller::RemoveSelectedText() { bool textRemoved( false ); - if( EventData::SELECTING == mImpl->mEventData->mState ) + if ( EventData::SELECTING == mImpl->mEventData->mState || + EventData::SELECTION_CHANGED == mImpl->mEventData->mState ) { std::string removedString; mImpl->RetrieveSelection( removedString, true ); @@ -1502,48 +1506,33 @@ void Controller::TapEvent( unsigned int tapCount, float x, float y ) if( NULL != mImpl->mEventData ) { - DALI_LOG_INFO( gLogFilter, Debug::Concise, "TapEvent state:%d \n", mImpl->mEventData->mState ); - if( 1u == tapCount ) { // This is to avoid unnecessary relayouts when tapping an empty text-field bool relayoutNeeded( false ); - if ( EventData::EDITING_WITH_PASTE_POPUP == mImpl->mEventData->mState || EventData::EDITING_WITH_PASTE_POPUP == mImpl->mEventData->mState ) + if( mImpl->IsShowingRealText() && + EventData::EDITING == mImpl->mEventData->mState ) { - mImpl->ChangeState( EventData::EDITING_WITH_GRAB_HANDLE); // If Popup shown hide it here so can be shown again if required. - } - - if( mImpl->IsShowingRealText() && ( EventData::INACTIVE != mImpl->mEventData->mState ) ) - { - // Already in an active state so show a popup - if ( !mImpl->IsClipboardEmpty() ) - { - // Shows Paste popup but could show full popup with Selection options. ( EDITING_WITH_POPUP ) - mImpl->ChangeState( EventData::EDITING_WITH_PASTE_POPUP ); - } - else - { - mImpl->ChangeState( EventData::EDITING_WITH_GRAB_HANDLE ); - } + // Show grab handle on second tap + mImpl->ChangeState( EventData::EDITING_WITH_GRAB_HANDLE ); relayoutNeeded = true; } - else + else if( EventData::EDITING != mImpl->mEventData->mState && + EventData::EDITING_WITH_GRAB_HANDLE != mImpl->mEventData->mState ) { - if( mImpl->IsShowingPlaceholderText() && !mImpl->IsFocusedPlaceholderAvailable() ) + if( mImpl->IsShowingPlaceholderText() && ! mImpl->IsFocusedPlaceholderAvailable() ) { // Hide placeholder text ResetText(); } - - if ( EventData::INACTIVE == mImpl->mEventData->mState ) - { - mImpl->ChangeState( EventData::EDITING ); - } - else if ( !mImpl->IsClipboardEmpty() ) - { - mImpl->ChangeState( EventData::EDITING_WITH_POPUP ); - } + // Show cursor on first tap + mImpl->ChangeState( EventData::EDITING ); + relayoutNeeded = true; + } + else if( mImpl->IsShowingRealText() ) + { + // Move the cursor relayoutNeeded = true; } @@ -1574,7 +1563,6 @@ void Controller::TapEvent( unsigned int tapCount, float x, float y ) } void Controller::PanEvent( Gesture::State state, const Vector2& displacement ) - // Show cursor and grabhandle on first tap, this matches the behaviour of tapping when already editing { DALI_ASSERT_DEBUG( mImpl->mEventData && "Unexpected PanEvent" ); @@ -1632,11 +1620,16 @@ void Controller::LongPressEvent( Gesture::State state, float x, float y ) void Controller::SelectEvent( float x, float y, bool selectAll ) { - DALI_LOG_INFO( gLogFilter, Debug::Verbose, "Controller::SelectEvent\n" ); - if( mImpl->mEventData ) { - mImpl->ChangeState( EventData::SELECTING ); + if ( mImpl->mEventData->mState == EventData::SELECTING ) + { + mImpl->ChangeState( EventData::SELECTION_CHANGED ); + } + else + { + mImpl->ChangeState( EventData::SELECTING ); + } if( selectAll ) { @@ -1724,21 +1717,12 @@ void Controller::PasteText( const std::string& stringToPaste ) InsertText( stringToPaste, Text::Controller::COMMIT ); mImpl->ChangeState( EventData::EDITING ); mImpl->RequestRelayout(); - - // Do this last since it provides callbacks into application code - mImpl->mControlInterface.TextChanged(); } void Controller::PasteClipboardItemEvent() { - // Retrieve the clipboard contents first ClipboardEventNotifier notifier( ClipboardEventNotifier::Get() ); std::string stringToPaste( notifier.GetContent() ); - - // Commit the current pre-edit text; the contents of the clipboard should be appended - mImpl->ResetImfManager(); - - // Paste PasteText( stringToPaste ); } @@ -1821,7 +1805,7 @@ void Controller::TextPopupButtonTouched( Dali::Toolkit::TextSelectionPopup::Butt ImfManager::ImfCallbackData Controller::OnImfEvent( ImfManager& imfManager, const ImfManager::ImfEventData& imfEvent ) { - bool update = false; + bool update( false ); bool requestRelayout = false; std::string text; @@ -1913,7 +1897,8 @@ bool Controller::BackspaceKeyEvent() bool removed( false ); - if( EventData::SELECTING == mImpl->mEventData->mState ) + if ( EventData::SELECTING == mImpl->mEventData->mState || + EventData::SELECTION_CHANGED == mImpl->mEventData->mState ) { removed = RemoveSelectedText(); } @@ -1947,15 +1932,17 @@ void Controller::NotifyImfManager() { if( mImpl->mEventData ) { - if( mImpl->mEventData->mImfManager ) + ImfManager imfManager = ImfManager::Get(); + + if( imfManager ) { // Notifying IMF of a cursor change triggers a surrounding text request so updating it now. std::string text; GetText( text ); - mImpl->mEventData->mImfManager.SetSurroundingText( text ); + imfManager.SetSurroundingText( text ); - mImpl->mEventData->mImfManager.SetCursorPosition( GetLogicalCursorPosition() ); - mImpl->mEventData->mImfManager.NotifyCursorPosition(); + imfManager.SetCursorPosition( GetLogicalCursorPosition() ); + imfManager.NotifyCursorPosition(); } } } diff --git a/dali-toolkit/public-api/accessibility-manager/accessibility-manager.h b/dali-toolkit/public-api/accessibility-manager/accessibility-manager.h index 48c2d70..08ce8ce 100644 --- a/dali-toolkit/public-api/accessibility-manager/accessibility-manager.h +++ b/dali-toolkit/public-api/accessibility-manager/accessibility-manager.h @@ -33,12 +33,12 @@ namespace Internal DALI_INTERNAL class AccessibilityManager; } /** - * @addtogroup dali_toolkit_managers + * @addtogroup dali-toolkit-accessibility-manager * @{ */ /** - * @brief Manages registration of actors in an accessibility focus chain and changing the + * @brief Manages registration of actors in a accessibility focus chain and changing the * focused actor within that chain. * * This class provides the functionality of registering the focus order and description @@ -48,7 +48,12 @@ class AccessibilityManager; * focus and moving the focus forward and backward. It also draws a highlight for the * focused actor and emits a signal when the focus is changed. * - * @since_tizen 2.4 + * Signals + * | %Signal Name | Method | + * |-------------------------|------------------------------------| + * | focus-changed | @ref FocusChangedSignal() | + * | focus-overshot | @ref FocusOvershotSignal() | + * | focused-actor-activated | @ref FocusedActorActivatedSignal() | */ class DALI_IMPORT_API AccessibilityManager : public BaseHandle { @@ -57,65 +62,51 @@ public: // Typedefs /** - * @brief General accessibility action signal. + * @brief Accessibility Action Signal. * * The connected signal callback should return true if handled. - * @since_tizen 2.4 */ - typedef Signal< bool ( AccessibilityManager& ) > AccessibilityActionSignalType; - - /** - * @brief Scroll accessibility action signal. - * - * The connected signal callback should return true if handled. - * @since_tizen 2.4 - */ - typedef Signal< bool ( AccessibilityManager&, const Dali::TouchEvent& )> AccessibilityActionScrollSignalType; + typedef Signal< bool ( AccessibilityManager& ) > AccessibilityActionSignalType; ///< Generic signal type + typedef Signal< bool ( AccessibilityManager&, const Dali::TouchEvent& )> AccessibilityActionScrollSignalType; ///< Scroll signal type /** * @brief Accessibility needs four information which will be read by screen-reader. * * Reading order : Label -> Trait -> Optional (Value and Hint) - * @since_tizen 2.4 */ enum AccessibilityAttribute { - ACCESSIBILITY_LABEL = 0, ///< Simple text which contained in ui-control @since_tizen 2.4 - ACCESSIBILITY_TRAIT, ///< Description of ui-control trait @since_tizen 2.4 - ACCESSIBILITY_VALUE, ///< Current value of ui-control (Optional) @since_tizen 2.4 - ACCESSIBILITY_HINT, ///< Hint for action (Optional) @since_tizen 2.4 - ACCESSIBILITY_ATTRIBUTE_NUM ///< Number of attributes @since_tizen 2.4 + ACCESSIBILITY_LABEL = 0, ///< Simple text which contained in ui-control + ACCESSIBILITY_TRAIT, ///< Description of ui-control trait + ACCESSIBILITY_VALUE, ///< Current value of ui-control (Optional) + ACCESSIBILITY_HINT, ///< Hint for action (Optional) + ACCESSIBILITY_ATTRIBUTE_NUM ///< Number of attributes }; /** * @brief Overshoot direction. - * @since_tizen 2.4 */ enum FocusOvershotDirection { - OVERSHOT_PREVIOUS = -1, ///< Try to move previous of the first actor @since_tizen 2.4 - OVERSHOT_NEXT = 1, ///< Try to move next of the last actor @since_tizen 2.4 + OVERSHOT_PREVIOUS = -1, ///< Try to move previous of the first actor + OVERSHOT_NEXT = 1, ///< Try to move next of the last actor }; public: /// @brief Focus changed signal - /// @since_tizen 2.4 typedef Signal< void ( Actor, Actor ) > FocusChangedSignalType; /// @brief Focus overshooted signal - /// @since_tizen 2.4 typedef Signal< void ( Actor, FocusOvershotDirection ) > FocusOvershotSignalType; /// @brief Focused actor activated signal - /// @since_tizen 2.4 typedef Signal< void ( Actor ) > FocusedActorActivatedSignalType; /** * @brief Create a AccessibilityManager handle; this can be initialised with AccessibilityManager::New(). * * Calling member functions with an uninitialised handle is not allowed. - * @since_tizen 2.4 */ AccessibilityManager(); @@ -123,14 +114,12 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~AccessibilityManager(); /** * @brief Get the singleton of AccessibilityManager object. * - * @since_tizen 2.4 * @return A handle to the AccessibilityManager control. */ static AccessibilityManager Get(); @@ -138,24 +127,22 @@ public: /** * @brief Set the information of the specified actor's accessibility attribute. * - * @since_tizen 2.4 + * @pre The AccessibilityManager has been initialized. + * @pre The Actor has been initialized. * @param actor The actor the text to be set with * @param type The attribute type the text to be set with * @param text The text for the actor's accessibility information - * @pre The AccessibilityManager has been initialized. - * @pre The Actor has been initialized. */ void SetAccessibilityAttribute(Actor actor, AccessibilityAttribute type, const std::string& text); /** * @brief Get the text of the specified actor's accessibility attribute. * - * @since_tizen 2.4 + * @pre The AccessibilityManager has been initialized. + * @pre The Actor has been initialized. * @param actor The actor to be queried * @param type The attribute type to be queried * @return The text of the actor's accessibility information - * @pre The AccessibilityManager has been initialized. - * @pre The Actor has been initialized. */ std::string GetAccessibilityAttribute(Actor actor, AccessibilityAttribute type) const; @@ -172,11 +159,10 @@ public: * description but with no focus order being set yet) and therefore * that actor is not focusable. * - * @since_tizen 2.4 - * @param actor The actor the focus order to be set with - * @param order The focus order of the actor * @pre The AccessibilityManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor the focus order to be set with + * @param order The focus order of the actor */ void SetFocusOrder(Actor actor, const unsigned int order); @@ -186,11 +172,10 @@ public: * When the focus order is 0, it means the focus order of the actor * is undefined. * - * @since_tizen 2.4 - * @param actor The actor to be queried - * @return The focus order of the actor * @pre The AccessibilityManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor to be queried + * @return The focus order of the actor */ unsigned int GetFocusOrder(Actor actor) const; @@ -205,9 +190,8 @@ public: * 1 where FOLast is the focus order of the very last control in the * focus chain. * - * @since_tizen 2.4 - * @return The focus order of the actor * @pre The AccessibilityManager has been initialized. + * @return The focus order of the actor */ unsigned int GenerateNewFocusOrder() const; @@ -217,12 +201,11 @@ public: * It will return an empty handle if the actor is not in the stage * or has a focus order of 0. * - * @since_tizen 2.4 + * @pre The AccessibilityManager has been initialized. * @param order The focus order of the actor * * @return The actor that has the specified focus order or an empty * handle if no actor in the stage has the specified focus order. - * @pre The AccessibilityManager has been initialized. */ Actor GetActorByFocusOrder(const unsigned int order); @@ -233,42 +216,38 @@ public: * have a defined focus order and must be focusable, visible and in * the stage. * - * @since_tizen 2.4 - * @param actor The actor to be focused - * @return Whether the focus is successful or not * @pre The AccessibilityManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor to be focused + * @return Whether the focus is successful or not */ bool SetCurrentFocusActor(Actor actor); /** * @brief Get the current focused actor. * - * @since_tizen 2.4 - * @return A handle to the current focused actor or an empty handle if no actor is focused. * @pre The AccessibilityManager has been initialized. + * @return A handle to the current focused actor or an empty handle if no actor is focused. */ Actor GetCurrentFocusActor(); /** * @brief Get the focus group of current focused actor. * - * @since_tizen 2.4 + * @pre The AccessibilityManager has been initialized. + * * @return A handle to the immediate parent of the current focused * actor which is also a focus group, or an empty handle if no actor * is focused. - * @pre The AccessibilityManager has been initialized. - * */ Actor GetCurrentFocusGroup(); /** * @brief Get the focus order of currently focused actor. - * @since_tizen 2.4 - * @return The focus order of the currently focused actor or 0 if no - * actor is in focus. * @pre The AccessibilityManager has been initialized. * + * @return The focus order of the currently focused actor or 0 if no + * actor is in focus. */ unsigned int GetCurrentFocusOrder(); @@ -279,9 +258,8 @@ public: * When the focus movement is wrapped around, the focus will be moved * to the first focusable actor when it reaches the end of the focus chain. * - * @since_tizen 2.4 - * @return true if the moving was successful * @pre The AccessibilityManager has been initialized. + * @return true if the moving was successful */ bool MoveFocusForward(); @@ -293,9 +271,8 @@ public: * moved to the last focusable actor when it reaches the beginning * of the focus chain. * - * @since_tizen 2.4 - * @return true if the moving was successful * @pre The AccessibilityManager has been initialized. + * @return true if the moving was successful */ bool MoveFocusBackward(); @@ -304,14 +281,12 @@ public: * that no actor is focused in the focus chain. * * It will emit focus changed signal without current focused actor - * @since_tizen 2.4 * @pre The AccessibilityManager has been initialized. */ void ClearFocus(); /** * @brief Clear the every registered focusable actor from focus-manager. - * @since_tizen 2.4 * @pre The AccessibilityManager has been initialized. */ void Reset(); @@ -320,22 +295,20 @@ public: * @brief Set whether an actor is a focus group that can limit the * scope of focus movement to its child actors in the focus chain. * - * @since_tizen 2.4 - * @param actor The actor to be set as a focus group. - * @param isFocusGroup Whether to set the actor to be a focus group or not. * @pre The AccessibilityManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor to be set as a focus group. + * @param isFocusGroup Whether to set the actor to be a focus group or not. */ void SetFocusGroup(Actor actor, bool isFocusGroup); /** * @brief Check whether the actor is set as a focus group or not. * - * @since_tizen 2.4 - * @param actor The actor to be checked. - * @return Whether the actor is set as a focus group. * @pre The AccessibilityManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor to be checked. + * @return Whether the actor is set as a focus group. */ bool IsFocusGroup(Actor actor) const; @@ -345,18 +318,16 @@ public: * When the group mode is enabled, the focus movement will be limited to the child actors * of the current focus group including the current focus group itself. The current focus * group is the closest ancestor of the current focused actor that set as a focus group. - * @since_tizen 2.4 - * @param enabled Whether the group mode is enabled or not * @pre The AccessibilityManager has been initialized. + * @param enabled Whether the group mode is enabled or not */ void SetGroupMode(bool enabled); /** * @brief Get whether the group mode is enabled or not. * - * @since_tizen 2.4 - * @return Whether the group mode is enabled or not. * @pre The AccessibilityManager has been initialized. + * @return Whether the group mode is enabled or not. */ bool GetGroupMode() const; @@ -366,18 +337,16 @@ public: * * When both the wrap mode and the group mode are enabled, focus will be * wrapped within the current focus group. Focus will not be wrapped in default. - * @since_tizen 2.4 - * @param wrapped Whether the focus movement is wrapped around or not * @pre The AccessibilityManager has been initialized. + * @param wrapped Whether the focus movement is wrapped around or not */ void SetWrapMode(bool wrapped); /** * @brief Get whether the wrap mode is enabled or not. * - * @since_tizen 2.4 - * @return Whether the wrap mode is enabled or not. * @pre The AccessibilityManager has been initialized. + * @return Whether the wrap mode is enabled or not. */ bool GetWrapMode() const; @@ -388,26 +357,23 @@ public: * AccessibilityManager and will be added to the focused actor as a * highlight. * - * @since_tizen 2.4 - * @param indicator The indicator actor to be added * @pre The AccessibilityManager has been initialized. * @pre The indicator actor has been initialized. + * @param indicator The indicator actor to be added */ void SetFocusIndicatorActor(Actor indicator); /** * @brief Get the focus indicator actor. * - * @since_tizen 2.4 - * @return A handle to the focus indicator actor * @pre The AccessibilityManager has been initialized. + * @return A handle to the focus indicator actor */ Actor GetFocusIndicatorActor(); /** * @brief Returns the closest ancestor of the given actor that is a focus group. * - * @since_tizen 2.4 * @param actor The actor to be checked for its focus group * @return The focus group the given actor belongs to or an empty handle if the given actor doesn't belong to any focus group */ @@ -415,7 +381,6 @@ public: /** * @brief Returns the current position of the read action. - * @since_tizen 2.4 * @return The current event position. */ Vector2 GetReadPosition() const; @@ -429,9 +394,8 @@ public: * @code * void YourCallbackName(Actor originalFocusedActor, Actor currentFocusedActor); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ FocusChangedSignalType& FocusChangedSignal(); @@ -442,9 +406,8 @@ public: * @code * void YourCallbackName(Actor currentFocusedActor, FocusOvershotDirection direction); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ FocusOvershotSignalType& FocusOvershotSignal(); @@ -455,9 +418,8 @@ public: * @code * void YourCallbackName(Actor activatedActor); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ FocusedActorActivatedSignalType& FocusedActorActivatedSignal(); @@ -470,7 +432,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& StatusChangedSignal(); @@ -483,7 +444,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionNextSignal(); @@ -496,7 +456,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionPreviousSignal(); @@ -509,7 +468,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionActivateSignal(); @@ -522,7 +480,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionReadSignal(); @@ -535,7 +492,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionOverSignal(); @@ -548,7 +504,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionReadNextSignal(); @@ -561,7 +516,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionReadPreviousSignal(); @@ -574,7 +528,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionUpSignal(); @@ -587,7 +540,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionDownSignal(); @@ -600,7 +552,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionClearFocusSignal(); @@ -613,7 +564,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionBackSignal(); @@ -626,7 +576,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionScrollUpSignal(); @@ -639,7 +588,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionScrollDownSignal(); @@ -652,7 +600,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionPageLeftSignal(); @@ -665,7 +612,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionPageRightSignal(); @@ -678,7 +624,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionPageUpSignal(); @@ -691,7 +636,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionPageDownSignal(); @@ -704,7 +648,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionMoveToFirstSignal(); @@ -717,7 +660,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionMoveToLastSignal(); @@ -730,7 +672,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionReadFromTopSignal(); @@ -743,7 +684,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionReadFromNextSignal(); @@ -756,7 +696,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionZoomSignal(); @@ -769,7 +708,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionReadIndicatorInformationSignal(); @@ -782,7 +720,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionReadPauseResumeSignal(); @@ -795,7 +732,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionSignalType& ActionStartStopSignal(); @@ -808,7 +744,6 @@ public: * @code * bool YourCallback( AccessibilityManager& manager, const TouchEvent& event ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ AccessibilityActionScrollSignalType& ActionScrollSignal(); diff --git a/dali-toolkit/public-api/controls/alignment/alignment.h b/dali-toolkit/public-api/controls/alignment/alignment.h index 331ad10..5a9d56c 100644 --- a/dali-toolkit/public-api/controls/alignment/alignment.h +++ b/dali-toolkit/public-api/controls/alignment/alignment.h @@ -32,7 +32,7 @@ namespace Internal DALI_INTERNAL class Alignment; } /** - * @addtogroup dali_toolkit_controls_alignment + * @addtogroup dali-toolkit-controls-alignment * @{ */ @@ -40,7 +40,6 @@ class Alignment; * @brief Alignment is a container which provides an easy way to align other actors inside its boundary. * * Additionaly it provides a scaling property to resize the contained actors @see Scaling. - * @since_tizen 2.4 * @note The use of scaling property will override all constraints applied to actors. * * All actors added to an alignment are going to be set with the same anchor point and parent origin. And, if the scaling property is set to a value @@ -51,41 +50,37 @@ class DALI_IMPORT_API Alignment : public Control public: /** * @brief Different types of alignment. - * @since_tizen 2.4 */ enum Type { - HorizontalLeft = 1, ///< Horizontal left alignment @since_tizen 2.4 - HorizontalCenter = 2, ///< Horizontal center alignment @since_tizen 2.4 - HorizontalRight = 4, ///< Horizontal right alignment @since_tizen 2.4 - VerticalTop = 8, ///< Vertical top alignment @since_tizen 2.4 - VerticalCenter = 16, ///< Vertical center alignment @since_tizen 2.4 - VerticalBottom = 32 ///< Vertical bottom alignment @since_tizen 2.4 + HorizontalLeft = 1, + HorizontalCenter = 2, + HorizontalRight = 4, + VerticalTop = 8, + VerticalCenter = 16, + VerticalBottom = 32 }; /** * @brief Scaling determines how actors are scaled, to match the alignment's boundary. - * @since_tizen 2.4 */ enum Scaling { - ScaleNone, ///< The original size is kept. @since_tizen 2.4 - ScaleToFill, ///< Scale added actors to fill alignment's boundary. Aspect ratio is not maintained. @since_tizen 2.4 - ScaleToFitKeepAspect, ///< Scale added actors to fit within the alignment's boundary. Aspect ratio is maintained. @since_tizen 2.4 - ScaleToFillKeepAspect, ///< Scale added actors to fill the alignment's boundary. Aspect ratio is maintained, and the actor may exceed the alignment's boundary. @since_tizen 2.4 - ShrinkToFit, ///< If added actors are larger than the alignment's boundary it will be shrunk down to fit. Aspect ratio is not maintained @since_tizen 2.4 - ShrinkToFitKeepAspect, ///< If added actors are larger than the alignment's boundary it will be shrunk down to fit. Aspect ratio is maintained @since_tizen 2.4 + ScaleNone, ///< The original size is kept. + ScaleToFill, ///< Scale added actors to fill alignment's boundary. Aspect ratio is not maintained. + ScaleToFitKeepAspect, ///< Scale added actors to fit within the alignment's boundary. Aspect ratio is maintained. + ScaleToFillKeepAspect, ///< Scale added actors to fill the alignment's boundary. Aspect ratio is maintained, and the actor may exceed the alignment's boundary. + ShrinkToFit, ///< If added actors are larger than the alignment's boundary it will be shrunk down to fit. Aspect ratio is not maintained + ShrinkToFitKeepAspect, ///< If added actors are larger than the alignment's boundary it will be shrunk down to fit. Aspect ratio is maintained }; /** * @brief Structure describing the padding values. - * @since_tizen 2.4 */ struct Padding { /** * @brief Constructor - * @since_tizen 2.4 */ Padding() : left( 0.f ), @@ -98,7 +93,6 @@ public: /** * @brief Constructor * - * @since_tizen 2.4 * @param[in] l Left padding * @param[in] r Right padding * @param[in] t Top padding @@ -122,14 +116,12 @@ public: * @brief Create an Alignment handle; this can be initialised with Alignment::New(). * * Calling member functions with an uninitialised handle is not allowed. - * @since_tizen 2.4 */ Alignment(); /** * @brief Creates an alignment control. * - * @since_tizen 2.4 * @param [in] horizontal Specifies how to align actors horizontally. Could be HorizontalLeft, HorizontalCenter or HorizontalRight. By default HorizontalCenter. * @param [in] vertical Specifies how to align actors vertically. Could be VerticalTop, VerticalCenter or VerticalBottom. By default VerticalCenter. * @return A handle to the Alignment control. @@ -139,7 +131,6 @@ public: /** * @brief Copy constructor. Creates another handle that points to the same real object. * - * @since_tizen 2.4 * @param[in] alignment Object to copy. */ Alignment(const Alignment& alignment); @@ -148,17 +139,15 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~Alignment(); /** - * @brief Downcast a handle to Alignment handle. + * @brief Downcast an Object handle to Alignment. * * If handle points to a Alignment the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a Alignment or an uninitialized handle */ @@ -167,9 +156,8 @@ public: /** * @brief Sets the new alignment. By default ( HorizontalCenter | VerticalCenter ). * - * @since_tizen 2.4 - * @param [in] type The new alignment option. * @note there should only be one horizontal and one vertical policy + * @param [in] type The new alignment option. */ void SetAlignmentType( Type type ); @@ -185,7 +173,6 @@ public: * } * @endcode * - * @since_tizen 2.4 * @return the alignment value. */ Type GetAlignmentType() const; @@ -193,25 +180,22 @@ public: /** * @brief Sets how added actors scale to fit the alignment's boundary. * - * @since_tizen 2.4 - * @param[in] scaling The scaling property. * @see Scaling. + * @param[in] scaling The scaling property. */ void SetScaling( Scaling scaling ); /** * @brief Retrieves the scaling property. * - * @since_tizen 2.4 - * @return The scaling. * @see Scaling. + * @return The scaling. */ Scaling GetScaling() const; /** * @brief Set a padding value. * - * @since_tizen 2.4 * @param [in] padding The left, right, top, bottom padding values. */ void SetPadding( const Padding& padding ); @@ -219,7 +203,6 @@ public: /** * @brief Get the padding values. * - * @since_tizen 2.4 * @return The left, right, top, bottom padding values. */ const Padding& GetPadding() const; @@ -228,7 +211,6 @@ public: * @brief Assignment operator. * * Changes this handle to point to another real object. - * @since_tizen 2.4 * @param[in] alignment Object to copy * @return A reference to this */ @@ -239,7 +221,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL Alignment( Internal::Alignment& implementation ); @@ -247,7 +228,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL Alignment( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/buttons/button.h b/dali-toolkit/public-api/controls/buttons/button.h index 64f353c..f9d73a8 100644 --- a/dali-toolkit/public-api/controls/buttons/button.h +++ b/dali-toolkit/public-api/controls/buttons/button.h @@ -32,7 +32,7 @@ namespace Internal DALI_INTERNAL class Button; } /** - * @addtogroup dali_toolkit_controls_buttons + * @addtogroup dali-toolkit-controls-buttons * @{ */ @@ -68,8 +68,18 @@ class Button; * * Is not mandatory set all images. A button could be defined only by setting its \e background image or by setting its \e background and \e selected images. * + * Signals + * | %Signal Name | Method | + * |-------------------|-----------------------------| + * | pressed | @ref PressedSignal() | + * | released | @ref ReleasedSignal() | + * | clicked | @ref ClickedSignal() | + * | state-changed | @ref StateChangedSignal() | * - * @since_tizen 2.4 + * Actions + * | %Action Name | %Button method called | + * |-------------------|-----------------------------| + * | button-click | %DoClickAction() | */ class DALI_IMPORT_API Button : public Control { @@ -77,37 +87,35 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices }; /** * @brief An enumeration of properties belonging to the Button class. - * @since_tizen 2.4 */ struct Property { enum { - DISABLED = PROPERTY_START_INDEX, ///< type bool @since_tizen 2.4 @see SetDisabled() - AUTO_REPEATING, ///< type bool @since_tizen 2.4 @see SetAutoRepeating() - INITIAL_AUTO_REPEATING_DELAY, ///< type float @since_tizen 2.4 @see SetInitialAutoRepeatingDelay() - NEXT_AUTO_REPEATING_DELAY, ///< type float @since_tizen 2.4 @see SetNextAutoRepeatingDelay() - TOGGLABLE, ///< type bool @since_tizen 2.4 @see SetTogglableButton() - SELECTED, ///< type bool @since_tizen 2.4 @see SetSelected() - UNSELECTED_STATE_IMAGE, ///< type std::string @since_tizen 2.4 @see SetUnselectedImage() - SELECTED_STATE_IMAGE, ///< type std::string @since_tizen 2.4 @see SetSelectedImage() - DISABLED_STATE_IMAGE, ///< type std::string @since_tizen 2.4 @see SetDisabledImage() - UNSELECTED_COLOR, ///< type Vector4 @since_tizen 2.4 - SELECTED_COLOR, ///< type Vector4 @since_tizen 2.4 - LABEL, ///< type Property::Map @since_tizen 2.4 + DISABLED = PROPERTY_START_INDEX, ///< name "disabled", @see SetDisabled(), type bool + AUTO_REPEATING, ///< name "auto-repeating", @see SetAutoRepeating(), type bool + INITIAL_AUTO_REPEATING_DELAY, ///< name "initial-auto-repeating-delay", @see SetInitialAutoRepeatingDelay(), type float + NEXT_AUTO_REPEATING_DELAY, ///< name "next-auto-repeating-delay", @see SetNextAutoRepeatingDelay(), type float + TOGGLABLE, ///< name "togglable", @see SetTogglableButton(), type bool + SELECTED, ///< name "selected", @see SetSelected(), type bool + UNSELECTED_STATE_IMAGE, ///< name "unselected-state-image", @see SetUnselectedImage(), type std::string + SELECTED_STATE_IMAGE, ///< name "selected-state-image", @see SetSelectedImage(), type std::string + DISABLED_STATE_IMAGE, ///< name "disabled-state-image", @see SetDisabledImage(), type std::string + UNSELECTED_COLOR, ///< name "unselected-color", type Vector4 + SELECTED_COLOR, ///< name "selected-color", type Vector4 + LABEL, ///< name "label", type Property::Map // Deprecated properties: - LABEL_TEXT, ///< type std::string @since_tizen 2.4 @see SetLabelText() + LABEL_TEXT, ///< name "label-text", @see SetLabelText(), type std::string }; }; @@ -118,29 +126,25 @@ public: * * Only derived versions can be instantiated. Calling member * functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ Button(); /** * @brief Copy constructor. - * @since_tizen 2.4 */ Button( const Button& button ); /** * @brief Assignment operator. - * @since_tizen 2.4 */ Button& operator=( const Button& button ); /** - * @brief Downcast a handle to Button handle. + * @brief Downcast an Object handle to Button. * * If handle points to a Button the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a Button or an uninitialized handle */ @@ -150,7 +154,6 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~Button(); @@ -159,14 +162,11 @@ public: * * No signals are emitted when the \e disabled property is set. * - * @since_tizen 2.4 * @param[in] disabled property. */ void SetDisabled( bool disabled ); /** - * @brief Returns if the button is disabled. - * @since_tizen 2.4 * @return \e true if the button is \e disabled. */ bool IsDisabled() const; @@ -177,14 +177,11 @@ public: * If the \e autorepeating property is set to \e true, then the \e togglable property is set to false * but no signal is emitted. * - * @since_tizen 2.4 * @param[in] autoRepeating \e autorepeating property. */ void SetAutoRepeating( bool autoRepeating ); /** - * @brief Returns if the autorepeating property is set. - * @since_tizen 2.4 * @return \e true if the \e autorepeating property is set. */ bool IsAutoRepeating() const; @@ -194,15 +191,12 @@ public: * * By default this value is set to 0.15 seconds. * - * @since_tizen 2.4 - * @param[in] initialAutoRepeatingDelay in seconds. * @pre initialAutoRepeatingDelay must be greater than zero. + * @param[in] initialAutoRepeatingDelay in seconds. */ void SetInitialAutoRepeatingDelay( float initialAutoRepeatingDelay ); /** - * @brief Gets the initial autorepeating delay in seconds. - * @since_tizen 2.4 * @return the initial autorepeating delay in seconds. */ float GetInitialAutoRepeatingDelay() const; @@ -212,15 +206,12 @@ public: * * By default this value is set to 0.05 seconds. * - * @since_tizen 2.4 - * @param[in] nextAutoRepeatingDelay in seconds. * @pre nextAutoRepeatingDelay must be greater than zero. + * @param[in] nextAutoRepeatingDelay in seconds. */ void SetNextAutoRepeatingDelay( float nextAutoRepeatingDelay ); /** - * @brief Gets the next autorepeating delay in seconds. - * @since_tizen 2.4 * @return the next autorepeating delay in seconds. */ float GetNextAutoRepeatingDelay() const; @@ -230,41 +221,34 @@ public: * * If the \e togglable property is set to \e true, then the \e autorepeating property is set to false. * - * @since_tizen 2.4 * @param[in] togglable property. */ void SetTogglableButton( bool togglable ); /** - * @brief Returns if the togglable property is set. - * @since_tizen 2.4 * @return \e true if the \e togglable property is set. */ bool IsTogglableButton() const; /** - * @brief Sets the button as selected or unselected. + * Sets the button as selected or unselected. * * \e togglable property must be set to \e true. * * Emits a Button::StateChangedSignal() signal. * - * @since_tizen 2.4 * @param[in] selected property. */ void SetSelected( bool selected ); /** - * @brief Returns if the selected property is set and the button is togglable. - * @since_tizen 2.4 - * @return \e true if the button is \e selected. + * @return \e true if the \e selected property is set and the button is togglable. */ bool IsSelected() const; /** * @brief Sets the animation time. * - * @since_tizen 2.4 * @param[in] animationTime The animation time in seconds. */ void SetAnimationTime( float animationTime ); @@ -272,7 +256,6 @@ public: /** * @brief Retrieves button's animation time. * - * @since_tizen 2.4 * @return The animation time in seconds. */ float GetAnimationTime() const; @@ -280,7 +263,6 @@ public: /** * @brief Sets the button's label. * - * @since_tizen 2.4 * @param[in] label The label text. */ void SetLabelText( const std::string& label ); @@ -288,7 +270,6 @@ public: /** * @brief Gets the label. * - * @since_tizen 2.4 * @return The label text. */ std::string GetLabelText() const; @@ -296,7 +277,6 @@ public: /** * @brief Sets the unselected button image. * - * @since_tizen 2.4 * @param[in] filename The button image. */ void SetUnselectedImage( const std::string& filename ); @@ -304,7 +284,6 @@ public: /** * @brief Sets the background image. * - * @since_tizen 2.4 * @param[in] filename The background image. */ void SetBackgroundImage( const std::string& filename ); @@ -312,7 +291,6 @@ public: /** * @brief Sets the selected image. * - * @since_tizen 2.4 * @param[in] filename The selected image. */ void SetSelectedImage( const std::string& filename ); @@ -320,7 +298,6 @@ public: /** * @brief Sets the selected background image. * - * @since_tizen 2.4 * @param[in] filename The selected background image. */ void SetSelectedBackgroundImage( const std::string& filename ); @@ -328,7 +305,6 @@ public: /** * @brief Sets the disabled background image. * - * @since_tizen 2.4 * @param[in] filename The disabled background image. */ void SetDisabledBackgroundImage( const std::string& filename ); @@ -336,7 +312,6 @@ public: /** * @brief Sets the disabled button image. * - * @since_tizen 2.4 * @param[in] filename The disabled button image. */ void SetDisabledImage( const std::string& filename ); @@ -344,56 +319,48 @@ public: /** * @brief Sets the disabled selected button image. * - * @since_tizen 2.4 * @param[in] filename The disabled selected button image. */ void SetDisabledSelectedImage( const std::string& filename ); + /// @cond INTERNAL + // Deprecated API + /** - * @brief Sets the label with an actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use @ref SetLabelText. + * @deprecated Sets the label with an actor. * @param[in] label The actor to use as a label */ void SetLabel( Actor label ); /** - * @brief Sets the button image. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use @ref SetUnselectedImage. + * @deprecated Sets the button image. * @param[in] image The button image. */ void SetButtonImage( Image image ); /** - * @brief Sets the selected image. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use SetSelectedImage( const std::string& filename ). + * @deprecated Sets the selected image. * @param[in] image The selected image. */ void SetSelectedImage( Image image ); /** - * @brief Gets the button image. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. + * @deprecated Gets the button image. * @return An actor with the button image. */ Actor GetButtonImage() const; /** - * @brief Gets the selected image. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. + * @deprecated Gets the selected image. * @return An actor with the selected image. */ Actor GetSelectedImage() const; + /// @endcond public: //Signals /** * @brief Button signal type - * @since_tizen 2.4 */ typedef Signal< bool ( Button ) > ButtonSignalType; @@ -404,7 +371,6 @@ public: //Signals * @code * bool YourCallbackName( Button button ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ ButtonSignalType& PressedSignal(); @@ -416,7 +382,6 @@ public: //Signals * @code * bool YourCallbackName( Button button ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ ButtonSignalType& ReleasedSignal(); @@ -428,21 +393,18 @@ public: //Signals * @code * bool YourCallbackName( Button button ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ ButtonSignalType& ClickedSignal(); /** * @brief This signal is emitted when the button's state is changed. - * * The application can get the state by calling IsSelected(). * * A callback of the following type may be connected: * @code * bool YourCallbackName( Button button ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ ButtonSignalType& StateChangedSignal(); @@ -452,7 +414,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL Button( Internal::Button& implementation ); @@ -460,7 +421,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ DALI_INTERNAL Button( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/buttons/check-box-button.h b/dali-toolkit/public-api/controls/buttons/check-box-button.h index 6b121e1..357c3e1 100644 --- a/dali-toolkit/public-api/controls/buttons/check-box-button.h +++ b/dali-toolkit/public-api/controls/buttons/check-box-button.h @@ -34,46 +34,43 @@ namespace Internal DALI_INTERNAL class CheckBoxButton; } /** - * @addtogroup dali_toolkit_controls_buttons + * @addtogroup dali-toolkit-controls-buttons * @{ */ /** - * @brief CheckBoxButton provides a check box button which user can check or uncheck. + * CheckBoxButton provides a check box button which user can check or uncheck. * * By default a CheckBoxButton emits a Button::ClickedSignal() signal when the button changes its state to selected or unselected. * - * The button's appearance could be modified by Button::SetUnselectedImage, Button::SetBackgroundImage, - * Button::SetSelectedImage, Button::SetSelectedBackgroundImage, Button::SetDisabledBackgroundImage, - * Button::SetDisabledImage, and Button::SetDisabledSelectedImage. + * The button's appearance could be modified by setting images or actors with CheckBoxButton::SetBackgroundImage, + * CheckBoxButton::SetSelectedImage, CheckBoxButton::SetDisabledBackgroundImage and CheckBoxButton::SetDisabledSelectedImage. * * When the button is not disabled, if it's not selected it only shows the \e background image. The \e selected image is shown over the * \e background image when the box is selected (\e background image is not replaced by \e selected image). * * When the button is disabled, \e background image and \e selected image are replaced by \e disabled images. * - * @since_tizen 2.4 + * CheckBoxButton doesn't have a text. However, a Dali::Toolkit::TableView with a Dali::TextActor or a Dali::Toolkit::TextView + * and a CheckBoxButton could be used instead. */ class DALI_IMPORT_API CheckBoxButton : public Button { public: /** - * @brief Create an uninitialized CheckBoxButton; this can be initialized with CheckBoxButton::New() + * Create an uninitialized CheckBoxButton; this can be initialized with CheckBoxButton::New() * Calling member functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ CheckBoxButton(); /** - * @brief Copy constructor. - * @since_tizen 2.4 + * Copy constructor. */ CheckBoxButton( const CheckBoxButton& checkBox ); /** - * @brief Assignment operator. - * @since_tizen 2.4 + * Assignment operator. */ CheckBoxButton& operator=( const CheckBoxButton& checkBox ); @@ -81,23 +78,18 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~CheckBoxButton(); /** - * @brief Create an initialized CheckBoxButton. - * @since_tizen 2.4 + * Create an initialized CheckBoxButton. * @return A handle to a newly allocated Dali resource. */ static CheckBoxButton New(); /** - * @brief Downcast a handle to CheckBoxButton handle. - * - * If handle points to a CheckBoxButton the + * Downcast an Object handle to CheckBoxButton. If handle points to a CheckBoxButton the * downcast produces valid handle. If not the returned handle is left uninitialized. - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a CheckBoxButton or an uninitialized handle */ @@ -106,15 +98,13 @@ public: public: // Not intended for application developers /** - * @brief Creates a handle using the Toolkit::Internal implementation. - * @since_tizen 2.4 + * Creates a handle using the Toolkit::Internal implementation. * @param[in] implementation The Control implementation. */ DALI_INTERNAL CheckBoxButton( Internal::CheckBoxButton& implementation ); /** - * @brief Allows the creation of this Control from an Internal::CustomActor pointer. - * @since_tizen 2.4 + * Allows the creation of this Control from an Internal::CustomActor pointer. * @param[in] internal A pointer to the internal CustomActor. */ DALI_INTERNAL CheckBoxButton( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/buttons/push-button.h b/dali-toolkit/public-api/controls/buttons/push-button.h index 9a3d7cf..14778cd 100644 --- a/dali-toolkit/public-api/controls/buttons/push-button.h +++ b/dali-toolkit/public-api/controls/buttons/push-button.h @@ -36,7 +36,7 @@ namespace Internal DALI_INTERNAL class PushButton; } /** - * @addtogroup dali_toolkit_controls_buttons + * @addtogroup dali-toolkit-controls-buttons * @{ */ @@ -47,7 +47,6 @@ class PushButton; * and a Button::ReleasedSignal() signal when it's released or having pressed it, the touch point leaves the boundary of the button. * * See Button for more detail on signals and modifying appearance via properties. - * @since_tizen 2.4 */ class DALI_IMPORT_API PushButton : public Button { @@ -55,27 +54,25 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Button::PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserving 1000 property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserving 1000 property indices }; /** * @brief An enumeration of properties belonging to the PushButton class. - * @since_tizen 2.4 */ struct Property { enum { - UNSELECTED_ICON = PROPERTY_START_INDEX, ///< Property, name "unselected-icon", type std::string @since_tizen 2.4 - SELECTED_ICON, ///< Property, name "selected-icon", type std::string @since_tizen 2.4 - ICON_ALIGNMENT, ///< Property, name "icon-alignment", type std::string @since_tizen 2.4 - LABEL_PADDING, ///< Property, name "label-padding", type Vector4 @since_tizen 2.4 - ICON_PADDING, ///< Property, name "icon-padding", type Vector4 @since_tizen 2.4 + UNSELECTED_ICON = PROPERTY_START_INDEX, ///< Property, name "unselected-icon", type std::string + SELECTED_ICON, ///< Property, name "selected-icon", type std::string + ICON_ALIGNMENT, ///< Property, name "icon-alignment", type std::string + LABEL_PADDING, ///< Property, name "label-padding", type Vector4 + ICON_PADDING, ///< Property, name "icon-padding", type Vector4 }; }; @@ -85,19 +82,16 @@ public: * @brief Create an uninitialized PushButton; this can be initialized with PushButton::New(). * * Calling member functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ PushButton(); /** * @brief Copy constructor. - * @since_tizen 2.4 */ PushButton( const PushButton& pushButton ); /** * @brief Assignment operator. - * @since_tizen 2.4 */ PushButton& operator=( const PushButton& pushButton ); @@ -105,37 +99,35 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~PushButton(); /** * @brief Create an initialized PushButton. * - * @since_tizen 2.4 * @return A handle to a newly allocated Dali resource. */ static PushButton New(); /** - * @brief Downcast a handle to PushButton handle. + * @brief Downcast an Object handle to PushButton. * * If handle points to a PushButton the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a PushButton or an uninitialized handle */ static PushButton DownCast( BaseHandle handle ); + /// @cond INTERNAL + // Deprecated API + using Button::SetButtonImage; /** - * @brief Sets the unselected image with an Actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use Button::SetUnselectedImage. + * @deprecated Sets the unselected image with an Actor. * @param[in] image The Actor to use. */ void SetButtonImage( Actor image ); @@ -143,9 +135,7 @@ public: using Button::SetBackgroundImage; /** - * @brief Sets the background image with an Actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use Button::SetBackgroundImage. + * @deprecated Sets the background image with an Actor. * @param[in] image The Actor to use. */ void SetBackgroundImage( Actor image ); @@ -153,9 +143,7 @@ public: using Button::SetSelectedImage; /** - * @brief Sets the selected image with an Actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use Button::SetSelectedImage( const std::string& filename ). + * @deprecated Sets the selected image with an Actor. * @param[in] image The Actor to use. */ void SetSelectedImage( Actor image ); @@ -163,9 +151,7 @@ public: using Button::SetSelectedBackgroundImage; /** - * @brief Sets the selected background image with an Actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use Button::SetSelectedBackgroundImage. + * @deprecated Sets the selected background image with an Actor. * @param[in] image The Actor to use. */ void SetSelectedBackgroundImage( Actor image ); @@ -173,9 +159,7 @@ public: using Button::SetDisabledBackgroundImage; /** - * @brief Sets the disabled background image with an Actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use Button::SetDisabledBackgroundImage. + * @deprecated Sets the disabled background image with an Actor. * @param[in] image The Actor to use. */ void SetDisabledBackgroundImage( Actor image ); @@ -183,9 +167,7 @@ public: using Button::SetDisabledImage; /** - * @brief Sets the disabled image with an Actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use Button::SetDisabledImage. + * @deprecated Sets the disabled image with an Actor. * @param[in] image The Actor to use. */ void SetDisabledImage( Actor image ); @@ -193,12 +175,11 @@ public: using Button::SetDisabledSelectedImage; /** - * @brief Sets the disabled selected image with an Actor. - * @since_tizen 2.4 - * @remarks Avoid using this method as it's a legacy code. Instead, use Button::SetDisabledSelectedImage. + * @deprecated Sets the disabled selected image with an Actor. * @param[in] image The Actor to use. */ void SetDisabledSelectedImage( Actor image ); + /// @endcond public: // Not intended for application developers @@ -206,7 +187,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL PushButton( Internal::PushButton& implementation ); @@ -214,7 +194,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ DALI_INTERNAL PushButton( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/buttons/radio-button.h b/dali-toolkit/public-api/controls/buttons/radio-button.h index 442fdbe..7c04b42 100644 --- a/dali-toolkit/public-api/controls/buttons/radio-button.h +++ b/dali-toolkit/public-api/controls/buttons/radio-button.h @@ -36,7 +36,7 @@ namespace Internal DALI_INTERNAL class RadioButton; } /** - * @addtogroup dali_toolkit_controls_buttons + * @addtogroup dali-toolkit-controls-buttons * @{ */ @@ -45,7 +45,7 @@ class RadioButton; * * Radio buttons are designed to select one of many option at the same time. * - * Every button have its own \e label and \e state, which can be modified by Button::SetLabelText and Button::SetSelected. + * Every button have its own \e label and \e state, which can be modified by RadioButton::SetLabel and Button::SetSelected. * * RadioButton can change its current state using Button::SetSelected. * @@ -56,7 +56,6 @@ class RadioButton; * When \e selected RadioButton is set to \e unselected no other RadioButtons in his group is set to \e selected. * * A Button::StateChangedSignal() is emitted when the RadioButton change its state to \e selected or \e unselected. - * @since_tizen 2.4 */ class DALI_IMPORT_API RadioButton: public Button { @@ -65,19 +64,16 @@ class DALI_IMPORT_API RadioButton: public Button * @brief Create an uninitialized RadioButton; this can be initialized with RadioButton::New(). * * Calling member functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ RadioButton(); /** * @brief Copy constructor. - * @since_tizen 2.4 */ RadioButton( const RadioButton& radioButton ); /** * @brief Assignment operator. - * @since_tizen 2.4 */ RadioButton& operator=( const RadioButton& radioButton ); @@ -85,14 +81,12 @@ class DALI_IMPORT_API RadioButton: public Button * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~RadioButton(); /** * @brief Create an initialized RadioButton. * - * @since_tizen 2.4 * @return A handle to a newly allocated Dali resource. */ static RadioButton New(); @@ -100,7 +94,6 @@ class DALI_IMPORT_API RadioButton: public Button /** * @brief Create an initialized RadioButton with given label. * - * @since_tizen 2.4 * @param[in] label The button label. * * @return A handle to a newly allocated Dali resource. @@ -108,12 +101,11 @@ class DALI_IMPORT_API RadioButton: public Button static RadioButton New( const std::string& label ); /** - * @brief Downcast a handle to RadioButton handle. + * @brief Downcast an Object handle to RadioButton. * * If handle points to a RadioButton the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a RadioButton or an uninitialized handle */ @@ -124,7 +116,6 @@ class DALI_IMPORT_API RadioButton: public Button /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL RadioButton( Internal::RadioButton& implementation ); @@ -132,7 +123,6 @@ class DALI_IMPORT_API RadioButton: public Button /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ DALI_INTERNAL RadioButton( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/control-depth-index-ranges.h b/dali-toolkit/public-api/controls/control-depth-index-ranges.h index 5651b04..ff5732c 100644 --- a/dali-toolkit/public-api/controls/control-depth-index-ranges.h +++ b/dali-toolkit/public-api/controls/control-depth-index-ranges.h @@ -24,7 +24,7 @@ namespace Dali namespace Toolkit { /** - * @addtogroup dali_toolkit_controls + * @addtogroup dali-toolkit-controls * @{ */ diff --git a/dali-toolkit/public-api/controls/control-impl.cpp b/dali-toolkit/public-api/controls/control-impl.cpp index 26c5087..b4b9cdb 100644 --- a/dali-toolkit/public-api/controls/control-impl.cpp +++ b/dali-toolkit/public-api/controls/control-impl.cpp @@ -234,7 +234,7 @@ Actor CreateBackground( Actor parent, const Vector4& color, Image image = Image( vertexBuffer = PropertyBuffer::New( vertexFormat, 4u ); vertexBuffer.SetData( gQuad ); - shader = Shader::New( VERTEX_SHADER_COLOR, FRAGMENT_SHADER_COLOR, Shader::HINT_OUTPUT_IS_TRANSPARENT ); + shader = Shader::New( VERTEX_SHADER_COLOR, FRAGMENT_SHADER_COLOR ); material = Material::New( shader ); //Create the index buffer @@ -975,8 +975,7 @@ void Control::OnStageConnection( int depth ) Renderer backgroundRenderer = mImpl->mBackground->actor.GetRendererAt( 0 ); if(backgroundRenderer) { - // lower background actor's depth to make visible behind of control - backgroundRenderer.SetDepthIndex( BACKGROUND_DEPTH_INDEX+depth - Layer::TREE_DEPTH_MULTIPLIER ); + backgroundRenderer.SetDepthIndex( BACKGROUND_DEPTH_INDEX+depth ); } } else @@ -985,8 +984,7 @@ void Control::OnStageConnection( int depth ) ImageActor imageActor = ImageActor::DownCast( mImpl->mBackground->actor ); if ( imageActor ) { - // lower background actor's depth to make visible behind of control - imageActor.SetSortModifier( BACKGROUND_DEPTH_INDEX+depth - Layer::TREE_DEPTH_MULTIPLIER ); + imageActor.SetSortModifier( BACKGROUND_DEPTH_INDEX+depth ); } } } diff --git a/dali-toolkit/public-api/controls/control-impl.h b/dali-toolkit/public-api/controls/control-impl.h index e63cece..b8ae6bb 100644 --- a/dali-toolkit/public-api/controls/control-impl.h +++ b/dali-toolkit/public-api/controls/control-impl.h @@ -36,16 +36,12 @@ namespace Dali namespace Toolkit { /** - * @addtogroup dali_toolkit_controls + * @addtogroup dali-toolkit-controls * @{ */ class StyleManager; -/** - * @brief Internal namespace for Control - * @since_tizen 2.4 - */ namespace Internal { /** @@ -54,7 +50,6 @@ namespace Internal * It will provide some common functionality required by all controls. * Implements ConnectionTrackerInterface so that signals (typically connected to member functions) will * be disconnected automatically when the control is destroyed. - * @since_tizen 2.4 */ class DALI_IMPORT_API Control : public CustomActorImpl, public ConnectionTrackerInterface { @@ -68,14 +63,12 @@ public: * @brief Create a new ControlImpl instance that does not require touch by default. * * If touch is required then the user can connect to this class' touch signal. - * @since_tizen 2.4 * @return A handle to the ControlImpl instance. */ static Toolkit::Control New(); /** * @brief Virtual destructor. - * @since_tizen 2.4 */ virtual ~Control(); @@ -122,7 +115,6 @@ public: * @code * EnableGestureDetection(Gesture::Type(Gesture::Pinch | Gesture::Tap | Gesture::Pan)); * @endcode - * @since_tizen 2.4 * @param[in] type The gesture type(s) to enable. */ void EnableGestureDetection( Gesture::Type type ); @@ -131,7 +123,6 @@ public: * @brief Allows deriving classes to disable any of the gesture detectors. * * Like EnableGestureDetection, this can also be called using bitwise or. - * @since_tizen 2.4 * @param[in] type The gesture type(s) to disable. * @see EnableGetureDetection */ @@ -142,7 +133,6 @@ public: * detection then they can access the gesture detector through this * API and modify the detection. * - * @since_tizen 2.4 * @return The pinch gesture detector. * @pre Pinch detection should have been enabled via EnableGestureDetection(). * @see EnableGestureDetection @@ -154,7 +144,6 @@ public: * detection then they can access the gesture detector through this * API and modify the detection. * - * @since_tizen 2.4 * @return The pan gesture detector. * @pre Pan detection should have been enabled via EnableGestureDetection(). * @see EnableGestureDetection @@ -166,7 +155,6 @@ public: * detection then they can access the gesture detector through this * API and modify the detection. * - * @since_tizen 2.4 * @return The tap gesture detector. * @pre Tap detection should have been enabled via EnableGestureDetection(). * @see EnableGestureDetection @@ -178,7 +166,6 @@ public: * detection then they can access the gesture detector through this * API and modify the detection. * - * @since_tizen 2.4 * @return The long press gesture detector. * @pre Long press detection should have been enabled via EnableGestureDetection(). * @see EnableGestureDetection @@ -193,7 +180,6 @@ public: * keyboard focus movement between its child actors). * * The control doesn't support it by default. - * @since_tizen 2.4 * @param[in] isSupported Whether this control supports two dimensional keyboard navigation. */ void SetKeyboardNavigationSupport( bool isSupported ); @@ -201,7 +187,6 @@ public: /** * @brief Gets whether this control supports two dimensional keyboard navigation. * - * @since_tizen 2.4 * @return true if this control supports two dimensional keyboard navigation. */ bool IsKeyboardNavigationSupported(); @@ -230,7 +215,6 @@ public: * * (i.e. the scope of keyboard focus movement * can be limitied to its child actors). The control is not a focus group by default. - * @since_tizen 2.4 * @param[in] isFocusGroup Whether this control is set as a focus group for keyboard navigation. */ void SetAsKeyboardFocusGroup( bool isFocusGroup ); @@ -238,20 +222,17 @@ public: /** * @brief Gets whether this control is a focus group for keyboard navigation. * - * @since_tizen 2.4 * @return true if this control is set as a focus group for keyboard navigation. */ bool IsKeyboardFocusGroup(); /** * @brief Called by the AccessibilityManager to activate the Control. - * @since_tizen 2.4 */ DALI_INTERNAL void AccessibilityActivate(); /** * @brief Called by the KeyboardFocusManager. - * @since_tizen 2.4 */ DALI_INTERNAL void KeyboardEnter(); @@ -275,7 +256,6 @@ public: /** * @brief Called by the KeyInputFocusManager to emit key event signals. * - * @since_tizen 2.4 * @param[in] event The key event. * @return True if the event was consumed. */ @@ -288,7 +268,6 @@ protected: // For derived classes to call * * Should be called last by the control after it acts on the Input Focus change. * - * @since_tizen 2.4 * @param[in] focusGained True if gained, False if lost */ void EmitKeyInputFocusSignal( bool focusGained ); @@ -397,8 +376,8 @@ protected: // Helpers for deriving classes // Flags for the constructor enum ControlBehaviour { - REQUIRES_STYLE_CHANGE_SIGNALS = 1 << ( CustomActorImpl::ACTOR_FLAG_COUNT + 0 ), ///< True if needs to monitor style change signals such as theme/font change @since_tizen 2.4 - REQUIRES_KEYBOARD_NAVIGATION_SUPPORT = 1 << ( CustomActorImpl::ACTOR_FLAG_COUNT + 1 ), ///< True if needs to support keyboard navigation @since_tizen 2.4 + REQUIRES_STYLE_CHANGE_SIGNALS = 1 << ( CustomActorImpl::ACTOR_FLAG_COUNT + 0 ), ///< True if needs to monitor style change signals such as theme/font change + REQUIRES_KEYBOARD_NAVIGATION_SUPPORT = 1 << ( CustomActorImpl::ACTOR_FLAG_COUNT + 1 ), ///< True if needs to support keyboard navigation LAST_CONTROL_BEHAVIOUR_FLAG }; @@ -408,14 +387,12 @@ protected: // Helpers for deriving classes /** * @brief Control constructor * - * @since_tizen 2.4 * @param[in] behaviourFlags Behavioural flags from ControlBehaviour enum */ Control( ControlBehaviour behaviourFlags ); /** * @brief Second phase initialization. - * @since_tizen 2.4 */ void Initialize(); @@ -427,7 +404,6 @@ public: // API for derived classes to override * @brief This method is called after the Control has been initialized. * * Derived classes should do any second phase initialization by overriding this method. - * @since_tizen 2.4 */ virtual void OnInitialize(); @@ -436,7 +412,6 @@ public: // API for derived classes to override * * Could be overridden by derived classes. * - * @since_tizen 2.4 * @param[in] child The added actor. */ virtual void OnControlChildAdd( Actor& child ); @@ -446,7 +421,6 @@ public: // API for derived classes to override * * Could be overridden by derived classes. * - * @since_tizen 2.4 * @param[in] child The removed actor. */ virtual void OnControlChildRemove( Actor& child ); @@ -456,7 +430,6 @@ public: // API for derived classes to override /** * @brief This method should be overridden by deriving classes requiring notifications when the style changes. * - * @since_tizen 2.4 * @param[in] styleManager The StyleManager object. * @param[in] change Information denoting what has changed. */ @@ -468,7 +441,6 @@ public: // API for derived classes to override * @brief This method is called when the control is accessibility activated. * * Derived classes should override this to perform custom accessibility activation. - * @since_tizen 2.4 * @return true if this control can perform accessibility activation. */ virtual bool OnAccessibilityActivated(); @@ -477,7 +449,6 @@ public: // API for derived classes to override * @brief This method should be overridden by deriving classes when they wish to respond the accessibility * pan gesture. * - * @since_tizen 2.4 * @param[in] gesture The pan gesture. * @return true if the pan gesture has been consumed by this control */ @@ -487,7 +458,6 @@ public: // API for derived classes to override * @brief This method should be overridden by deriving classes when they wish to respond the accessibility * touch event. * - * @since_tizen 2.4 * @param[in] touchEvent The touch event. * @return true if the touch event has been consumed by this control */ @@ -497,7 +467,6 @@ public: // API for derived classes to override * @brief This method should be overridden by deriving classes when they wish to respond * the accessibility up and down action (i.e. value change of slider control). * - * @since_tizen 2.4 * @param[in] isIncrease Whether the value should be increased or decreased * @return true if the value changed action has been consumed by this control */ @@ -507,7 +476,6 @@ public: // API for derived classes to override * @brief This method should be overridden by deriving classes when they wish to respond * the accessibility zoom action * - * @since_tizen 2.4 * @return true if the zoom action has been consumed by this control */ virtual bool OnAccessibilityZoom(); @@ -518,7 +486,6 @@ public: // API for derived classes to override * @brief Called when the control gains key input focus. * * Should be overridden by derived classes if they need to customize what happens when focus is gained. - * @since_tizen 2.4 */ virtual void OnKeyInputFocusGained(); @@ -526,7 +493,6 @@ public: // API for derived classes to override * @brief Called when the control loses key input focus. * * Should be overridden by derived classes if they need to customize what happens when focus is lost. - * @since_tizen 2.4 */ virtual void OnKeyInputFocusLost(); @@ -534,7 +500,6 @@ public: // API for derived classes to override * @brief Gets the next keyboard focusable actor in this control towards the given direction. * * A control needs to override this function in order to support two dimensional keyboard navigation. - * @since_tizen 2.4 * @param[in] currentFocusedActor The current focused actor. * @param[in] direction The direction to move the focus towards. * @param[in] loopEnabled Whether the focus movement should be looped within the control. @@ -548,7 +513,6 @@ public: // API for derived classes to override * This allows the application to preform any actions if wishes * before the focus is actually moved to the chosen actor. * - * @since_tizen 2.4 * @param[in] commitedFocusableActor The commited focusable actor. */ virtual void OnKeyboardFocusChangeCommitted( Actor commitedFocusableActor ); @@ -557,7 +521,6 @@ public: // API for derived classes to override * @brief This method is called when the control has enter pressed on it. * * Derived classes should override this to perform custom actions. - * @since_tizen 2.4 * @return true if this control supported this action. */ virtual bool OnKeyboardEnter(); @@ -571,10 +534,9 @@ public: // API for derived classes to override * is enabled. The default behaviour is to scale the control by the * pinch scale. * - * @since_tizen 2.4 - * @param[in] pinch The pinch gesture. * @note If overridden, then the default behaviour will not occur. * @note Pinch detection should be enabled via EnableGestureDetection(). + * @param[in] pinch The pinch gesture. * @see EnableGestureDetection */ virtual void OnPinch( const PinchGesture& pinch ); @@ -585,10 +547,9 @@ public: // API for derived classes to override * This should be overridden by deriving classes when pan detection * is enabled. * - * @since_tizen 2.4 - * @param[in] pan The pan gesture. * @note There is no default behaviour with panning. * @note Pan detection should be enabled via EnableGestureDetection(). + * @param[in] pan The pan gesture. * @see EnableGestureDetection */ virtual void OnPan( const PanGesture& pan ); @@ -599,10 +560,9 @@ public: // API for derived classes to override * This should be overridden by deriving classes when tap detection * is enabled. * - * @since_tizen 2.4 - * @param[in] tap The tap gesture. * @note There is no default behaviour with a tap. * @note Tap detection should be enabled via EnableGestureDetection(). + * @param[in] tap The tap gesture. * @see EnableGestureDetection */ virtual void OnTap( const TapGesture& tap ); @@ -613,10 +573,9 @@ public: // API for derived classes to override * This should be overridden by deriving classes when long press * detection is enabled. * - * @since_tizen 2.4 - * @param[in] longPress The long press gesture. * @note There is no default behaviour associated with a long press. * @note Long press detection should be enabled via EnableGestureDetection(). + * @param[in] longPress The long press gesture. * @see EnableGestureDetection */ virtual void OnLongPress( const LongPressGesture& longPress ); @@ -634,9 +593,8 @@ public: // API for derived classes to override virtual void SignalDisconnected( SlotObserver* slotObserver, CallbackBase* callback ); /** - * @brief Retrieve the extension for this control + * Retrieve the extension for this control * - * @since_tizen 2.4 * @return The extension if available, NULL otherwise */ virtual Extension* GetControlExtension() @@ -658,20 +616,18 @@ private: /** * @brief Get implementation from the handle * - * @since_tizen 2.4 + * @pre handle is initialized and points to a control * @param handle * @return implementation - * @pre handle is initialized and points to a control */ DALI_IMPORT_API Internal::Control& GetImplementation( Dali::Toolkit::Control& handle ); /** * @brief Get implementation from the handle * - * @since_tizen 2.4 + * @pre handle is initialized and points to a control * @param handle * @return implementation - * @pre handle is initialized and points to a control */ DALI_IMPORT_API const Internal::Control& GetImplementation( const Dali::Toolkit::Control& handle ); diff --git a/dali-toolkit/public-api/controls/control.h b/dali-toolkit/public-api/controls/control.h index bdf20dc..35587f9 100644 --- a/dali-toolkit/public-api/controls/control.h +++ b/dali-toolkit/public-api/controls/control.h @@ -41,7 +41,7 @@ namespace Internal class Control; } /** - * @addtogroup dali_toolkit_controls + * @addtogroup dali-toolkit-controls * @{ */ @@ -49,10 +49,23 @@ class Control; * @brief Control is the base class for all controls. * * The implementation of the control must be supplied; see Internal::Control for more details. - * @since_tizen 2.4 * @see Internal::Control * + * Signals + * | %Signal Name | Method | + * |------------------------|-----------------------------------------------------| + * | key-event | @ref KeyEventSignal() | + * | key-input-focus-gained | @ref KeyInputFocusGainedSignal() | + * | key-input-focus-lost | @ref KeyInputFocusLostSignal() | + * | tapped | @ref GetTapGestureDetector().DetectedSignal() | + * | panned | @ref GetPanGestureDetector().DetectedSignal() | + * | pinched | @ref GetPinchGestureDetector().DetectedSignal() | + * | long-pressed | @ref GetLongPressGestureDetector().DetectedSignal() | * + * Actions + * | %Action Name | %Control method called | + * |-------------------------|----------------------------------------------------| + * | accessibility-activated | %OnAccessibilityActivated() | */ class DALI_IMPORT_API Control : public CustomActor { @@ -60,53 +73,48 @@ public: /** * @brief The start and end property ranges for control. - * @since_tizen 2.4 */ enum PropertyRange { - PROPERTY_START_INDEX = PROPERTY_REGISTRATION_START_INDEX, ///< Start index is used by the property registration macro. @since_tizen 2.4 - CONTROL_PROPERTY_START_INDEX = PROPERTY_START_INDEX, ///< Start index of Control properties. @since_tizen 2.4 - CONTROL_PROPERTY_END_INDEX = CONTROL_PROPERTY_START_INDEX + 1000 ///< Reserving 1000 property indices. @since_tizen 2.4 + PROPERTY_START_INDEX = PROPERTY_REGISTRATION_START_INDEX, ///< Start index is used by the property registration macro. + CONTROL_PROPERTY_START_INDEX = PROPERTY_START_INDEX, ///< Start index of Control properties. + CONTROL_PROPERTY_END_INDEX = CONTROL_PROPERTY_START_INDEX + 1000 ///< Reserving 1000 property indices. }; /** * @brief An enumeration of properties belonging to the Control class. - * @since_tizen 2.4 */ struct Property { enum { - STYLE_NAME = PROPERTY_START_INDEX, ///< type std::string @since_tizen 2.4 @see SetStyleName - BACKGROUND_COLOR, ///< type Vector4 @since_tizen 2.4 @see SetBackgroundColor - BACKGROUND_IMAGE, ///< type Map @since_tizen 2.4 @see SetBackgroundImage - KEY_INPUT_FOCUS, ///< type bool @since_tizen 2.4 @see SetKeyInputFocus + STYLE_NAME = PROPERTY_START_INDEX, ///< name "style-name", @see SetStyleName, type std::string + BACKGROUND_COLOR, ///< name "background-color", @see SetBackgroundColor, type Vector4 + BACKGROUND_IMAGE, ///< name "background-image", @see SetBackgroundImage, type Map + KEY_INPUT_FOCUS, ///< name "key-input-focus", @see SetKeyInputFocus, type bool }; }; /** * @brief Describes the direction to move the keyboard focus towards. - * @since_tizen 2.4 */ struct KeyboardFocus { enum Direction { - LEFT, ///< Move keyboard focus towards the left direction @since_tizen 2.4 - RIGHT, ///< Move keyboard focus towards the right direction @since_tizen 2.4 - UP, ///< Move keyboard focus towards the up direction @since_tizen 2.4 - DOWN ///< Move keyboard focus towards the down direction @since_tizen 2.4 + LEFT, ///< Move keyboard focus towards the left direction + RIGHT, ///< Move keyboard focus towards the right direction + UP, ///< Move keyboard focus towards the up direction + DOWN ///< Move keyboard focus towards the down direction }; }; // Typedefs /// @brief Key Event signal type; - /// @since_tizen 2.4 typedef Signal KeyEventSignalType; /// @brief Key InputFocusType signal type; - /// @since_tizen 2.4 typedef Signal KeyInputFocusSignalType; public: // Creation & Destruction @@ -114,7 +122,6 @@ public: // Creation & Destruction /** * @brief Create a new instance of a Control. * - * @since_tizen 2.4 * @return A handle to a new Control. */ static Control New(); @@ -124,7 +131,6 @@ public: // Creation & Destruction * * Only derived versions can be instantiated. Calling member * functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ Control(); @@ -132,7 +138,6 @@ public: // Creation & Destruction * @brief Copy constructor. * * Creates another handle that points to the same real object - * @since_tizen 2.4 * @param[in] uiControl Handle to copy */ Control(const Control& uiControl); @@ -141,7 +146,6 @@ public: // Creation & Destruction * @brief Dali::Control is intended as a base class * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~Control(); @@ -151,7 +155,6 @@ public: // operators * @brief Assignment operator. * * Changes this handle to point to another real object - * @since_tizen 2.4 * @param[in] handle Object to assign this to * @return reference to this */ @@ -160,12 +163,11 @@ public: // operators public: /** - * @brief Downcast a handle to Control handle. + * @brief Downcast an Object handle to Control. * * If handle points to a Control the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a Control or an uninitialized handle */ @@ -177,25 +179,23 @@ public: * @brief This sets the control to receive key events. * * The key event can originate from a virtual or physical keyboard. - * @since_tizen 2.4 - * @return True if the control has foucs, False otherwise. * @pre The Control has been initialized. * @pre The Control should be on the stage before setting keyboard focus. + * @return True if the control has foucs, False otherwise. */ void SetKeyInputFocus(); /** * @brief Quries whether the control has key input focus. * - * @since_tizen 2.4 - * @return true if this control has keyboard input focus - * @pre The Control has been initialized. - * @pre The Control should be on the stage before setting keyboard focus. - * @note The control can be set to have the focus and still not receive all the key events if another control has over ridden it. + * Note: The control can be set to have the focus and still not receive all the key events if another control has over ridden it. * As the key input focus mechanism works like a stack, the top most control receives all the key events, and passes on the * unhandled events to the controls below in the stack. A control in the stack will regain key input focus when there are no more * controls above it in the focus stack. * To query for the conrol which is on top of the focus stack use Dali::Toolkit::KeyInputFocusManager::GetCurrentKeyboardFocusActor() + * @pre The Control has been initialized. + * @pre The Control should be on the stage before setting keyboard focus. + * @return true if this control has keyboard input focus */ bool HasKeyInputFocus(); @@ -203,7 +203,6 @@ public: * @brief Once an actor is Set to receive key input focus this function is called to stop it receiving key events. * * A check is performed to ensure it was previously set, if this check fails then nothing is done. - * @since_tizen 2.4 * @pre The Actor has been initialized. */ void ClearKeyInputFocus(); @@ -213,7 +212,6 @@ public: /** * @brief Retrieves the pinch gesture detector of the control. * - * @since_tizen 2.4 * @return The pinch gesture detector. * @note Will return an empty handle if the control does not handle the gesture itself. */ @@ -222,7 +220,6 @@ public: /** * @brief Retrieves the pan gesture detector of the control. * - * @since_tizen 2.4 * @return The pan gesture detector. * @note Will return an empty handle if the control does not handle the gesture itself. */ @@ -231,7 +228,6 @@ public: /** * @brief Retrieves the tap gesture detector of the control. * - * @since_tizen 2.4 * @return The tap gesture detector. * @note Will return an empty handle if the control does not handle the gesture itself. */ @@ -240,7 +236,6 @@ public: /** * @brief Retrieves the long press gesture detector of the control. * - * @since_tizen 2.4 * @return The long press gesture detector. * @note Will return an empty handle if the control does not handle the gesture itself. */ @@ -251,7 +246,6 @@ public: /** * @brief Sets the name of the style to be applied to the control. * - * @since_tizen 2.4 * @param[in] styleName A string matching a style described in a stylesheet. */ void SetStyleName( const std::string& styleName ); @@ -259,7 +253,6 @@ public: /** * @brief Retrieves the name of the style to be applied to the control (if any). * - * @since_tizen 2.4 * @return A string matching a style or an empty string. */ const std::string& GetStyleName() const; @@ -269,7 +262,6 @@ public: /** * @brief Sets the background color of the control. * - * @since_tizen 2.4 * @param[in] color The required background color of the control * * @note The background color fully blends with the actor color. @@ -279,7 +271,6 @@ public: /** * @brief Retrieves the background color of the control. * - * @since_tizen 2.4 * @return The background color of the control. */ Vector4 GetBackgroundColor() const; @@ -289,14 +280,12 @@ public: * * The color of this image is blended with the background color @see SetBackgroundColor * - * @since_tizen 2.4 * @param[in] image The image to set as the background. */ void SetBackgroundImage( Image image ); /** * @brief Clears the background. - * @since_tizen 2.4 */ void ClearBackground(); @@ -311,9 +300,8 @@ public: * @endcode * The return value of True, indicates that the event should be consumed. * Otherwise the signal will be emitted on the next parent of the actor. - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Control has been initialized. + * @return The signal to connect to. */ KeyEventSignalType& KeyEventSignal(); @@ -326,9 +314,8 @@ public: * @endcode * The return value of True, indicates that the event should be consumed. * Otherwise the signal will be emitted on the next parent of the actor. - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Control has been initialized. + * @return The signal to connect to. */ KeyInputFocusSignalType& KeyInputFocusGainedSignal(); @@ -343,9 +330,8 @@ public: * @endcode * The return value of True, indicates that the event should be consumed. * Otherwise the signal will be emitted on the next parent of the actor. - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Control has been initialized. + * @return The signal to connect to. */ KeyInputFocusSignalType& KeyInputFocusLostSignal(); @@ -354,7 +340,6 @@ public: // Intended for control developers /** * @brief Create an initialised Control. * - * @since_tizen 2.4 * @param[in] implementation The implementation for this control. * @return A handle to a newly allocated Dali resource. * @@ -366,7 +351,6 @@ public: // Intended for control developers * @brief This constructor is used by CustomActor within Dali core to create additional Control handles * using an Internal CustomActor pointer. * - * @since_tizen 2.4 * @param [in] internal A pointer to a newly allocated Dali resource */ explicit Control(Dali::Internal::CustomActor* internal); @@ -378,7 +362,6 @@ public: // Templates for Deriving Classes * * @tparam T The handle class * @tparam I The implementation class - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return Handle to a class T or an uninitialized handle. * @see DownCast(BaseHandle) @@ -409,7 +392,6 @@ public: // Templates for Deriving Classes * implementation of their class. * * @tparam I The implementation class - * @since_tizen 2.4 * @param[in] internal Pointer to the Internal::CustomActor */ template diff --git a/dali-toolkit/public-api/controls/default-controls/solid-color-actor.h b/dali-toolkit/public-api/controls/default-controls/solid-color-actor.h index 39e1a22..e1e95b6 100644 --- a/dali-toolkit/public-api/controls/default-controls/solid-color-actor.h +++ b/dali-toolkit/public-api/controls/default-controls/solid-color-actor.h @@ -28,23 +28,22 @@ namespace Dali namespace Toolkit { /** - * @addtogroup dali_toolkit_controls + * @internal + * @addtogroup dali-toolkit-controls-default-controls * @{ */ /** + * @deprecated * @brief Creates a Dali::ImageActor with a solid color, optionally it creates a border. * * If the \e border parameter is set to \e true, the Dali::ImageActor's style is set to Dali::ImageActor::STYLE_NINE_PATCH. * - * @since_tizen 2.4 - * @remarks Avoid using this function as it's a legacy code. Instead, use Control with background color. * @param[in] color The ImageActor's color. * @param[in] border If \e true, a border is created. By default, the value is set to \e false. * @param[in] borderColor The color for the ImageActor's border. By default, the value is set to Color::WHITE. * @param[in] borderSize The size for the ImageActor's border. By default, the value is set to 1 pixel. It supports under 10 pixel for clear result of gl blend * @return a handle to the new ImageActor - * @see Control */ DALI_IMPORT_API ImageActor CreateSolidColorActor( const Vector4& color, bool border = false, const Vector4& borderColor = Color::WHITE, const unsigned int borderSize = 1 ); diff --git a/dali-toolkit/public-api/controls/gaussian-blur-view/gaussian-blur-view.h b/dali-toolkit/public-api/controls/gaussian-blur-view/gaussian-blur-view.h index 16487bd..65639da 100644 --- a/dali-toolkit/public-api/controls/gaussian-blur-view/gaussian-blur-view.h +++ b/dali-toolkit/public-api/controls/gaussian-blur-view/gaussian-blur-view.h @@ -50,12 +50,12 @@ class BloomView; } // namespace Internal /** - * @addtogroup dali_toolkit_controls_gaussian_blur_view + * @addtogroup dali-toolkit-controls-gaussian-blur-view * @{ */ /** - * @brief + * * GaussianBlurView is a class for applying a render process that blurs an image. * * Basic idea:- @@ -76,7 +76,6 @@ class BloomView; * * Usage example:- * - * @code * // initialise\n * GaussianBlurView gaussianBlurView = GaussianBlurView::New();\n * @@ -100,36 +99,28 @@ class BloomView; * // Stop rendering the GaussianBlurView\n * Stage::GetCurrent().Remove(gaussianBlurView);\n * gaussianBlurView.Deactivate();\n - * @endcode - * @since_tizen 2.4 - * @remarks This is an experimental feature and might not be supported in the next release. - * We do recommend not to use this class. */ class DALI_IMPORT_API GaussianBlurView : public Control { public: /** - * @brief Signal type for notifications - * @since_tizen 2.4 + * Signal type for notifications */ typedef Signal< void (GaussianBlurView source) > GaussianBlurViewSignal; /** - * @brief Create an uninitialized GaussianBlurView; this can be initialized with GaussianBlurView::New() + * Create an uninitialized GaussianBlurView; this can be initialized with GaussianBlurView::New() * Calling member functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ GaussianBlurView(); /** - * @brief Copy constructor. Creates another handle that points to the same real object - * @since_tizen 2.4 + * Copy constructor. Creates another handle that points to the same real object */ GaussianBlurView(const GaussianBlurView& handle); /** - * @brief Assignment operator. Changes this handle to point to another real object - * @since_tizen 2.4 + * Assignment operator. Changes this handle to point to another real object */ GaussianBlurView& operator=(const GaussianBlurView& ZoomView); @@ -137,23 +128,19 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~GaussianBlurView(); /** - * @brief Downcast a handle to GaussianBlurView handle. - * - * If handle points to a GaussianBlurView the + * Downcast an Object handle to GaussianBlurView. If handle points to a GaussianBlurView the * downcast produces valid handle. If not the returned handle is left uninitialized. - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a GaussianBlurView or an uninitialized handle */ static GaussianBlurView DownCast( BaseHandle handle ); /** - * @brief Create an initialized GaussianBlurView, using default settings. The default settings are:-\n + * Create an initialized GaussianBlurView, using default settings. The default settings are:-\n * * numSamples = 5\n * blurBellCurveWidth = 1.5\n @@ -161,14 +148,12 @@ public: * downsampleWidthScale = 0.5\n * downsampleHeightScale = 0.5\n * blurUserImage = false - * @since_tizen 2.4 * @return A handle to a newly allocated Dali resource */ static GaussianBlurView New(); /** - * @brief Create an initialized GaussianBlurView. - * @since_tizen 2.4 + * Create an initialized GaussianBlurView. * @param numSamples The size of the Gaussian blur kernel (number of samples in horizontal / vertical blur directions). * @param blurBellCurveWidth The constant controlling the Gaussian function, must be > 0.0. Controls the width of the bell curve, i.e. the look of the blur and also indirectly * the amount of blurriness Smaller numbers for a tighter curve. Useful values in the range [0.5..3.0] - near the bottom of that range the curve is weighted heavily towards @@ -189,109 +174,90 @@ public: bool blurUserImage = false); /** - * @brief Adds a child Actor to this Actor. - * @since_tizen 2.4 - * @param [in] child The child. + * Adds a child Actor to this Actor. + * NOTE! if the child already has a parent, it will be removed from old parent + * and reparented to this actor. This may change childs position, color, shader effect, + * scale etc as it now inherits them from this actor * @pre This Actor (the parent) has been initialized. * @pre The child actor has been initialized. * @pre The child actor is not the same as the parent actor. * @pre The actor is not the Root actor + * @param [in] child The child. * @post The child will be referenced by its parent. This means that the child will be kept alive, * even if the handle passed into this method is reset or destroyed. - * @note if the child already has a parent, it will be removed from old parent - * and reparented to this actor. This may change childs position, color, shader effect, - * scale etc as it now inherits them from this actor */ void Add(Actor child); /** - * @brief Removes a child Actor from this Actor. - * + * Removes a child Actor from this Actor. * If the actor was not a child of this actor, this is a no-op. - * @since_tizen 2.4 - * @param [in] child The child. * @pre This Actor (the parent) has been initialized. * @pre The child actor is not the same as the parent actor. + * @param [in] child The child. */ void Remove(Actor child); /** - * @brief Start rendering the GaussianBlurView. Must be called after you Add() it to the stage. - * @since_tizen 2.4 + * Start rendering the GaussianBlurView. Must be called after you Add() it to the stage. */ void Activate(); /** - * @brief Render the GaussianBlurView once. - * - * Must be called after you Add() it to the stage. + * Render the GaussianBlurView once. Must be called after you Add() it to the stage. * Only works with a gaussian blur view created with blurUserImage = true. * Listen to the Finished signal to determine when the rendering has completed. - * @since_tizen 2.4 */ void ActivateOnce(); /** - * @brief Stop rendering the GaussianBlurView. Must be called after you Remove() it from the stage. - * @since_tizen 2.4 + * Stop rendering the GaussianBlurView. Must be called after you Remove() it from the stage. */ void Deactivate(); /** - * @brief Sets a custom image to be blurred and a render target to receive the blurred result. - * - * If this is called the children of the GaussianBlurObject will not be rendered blurred, + * Sets a custom image to be blurred and a render target to receive the blurred result. If this is called the children of the GaussianBlurObject will not be rendered blurred, * instead the inputImage will get blurred. * To retrieve the blurred image the user can either pass a handle on a render target they own as the second parameter to SetUserImageAndOutputRenderTarget( ... ), or they * can pass NULL for this parameter and instead call GetBlurredRenderTarget() which will return a handle on a render target created internally to the GaussianBlurView object. - * @since_tizen 2.4 + * @pre This object was created with a New( ... ) call where the blurUserImage argument was set to true. If this was not the case an exception will be thrown. * @param inputImage The image that the user wishes to blur. * @param outputRenderTarget A render target to receive the blurred result. Passing NULL is allowed. See also GetBlurredRenderTarget(). - * @pre This object was created with a New( ... ) call where the blurUserImage argument was set to true. If this was not the case an exception will be thrown. */ void SetUserImageAndOutputRenderTarget(Image inputImage, FrameBufferImage outputRenderTarget); /** - * @brief Get the index of the property that can be used to fade the blur in / out. - * - * This is the overall strength of the blur. + * Get the index of the property that can be used to fade the blur in / out. This is the overall strength of the blur. * User can use this to animate the blur. A value of 0.0 is zero blur and 1.0 is full blur. Default is 1.0. * Note that if you set the blur to 0.0, the result will be no blur BUT the internal rendering will still be happening. If you wish to turn the blur off, you should remove * the GaussianBlurView object from the stage also. - * @since_tizen 2.4 * @return Index of the property that can be used to fade the blur in / out */ Dali::Property::Index GetBlurStrengthPropertyIndex() const; /** - * @brief Get the final blurred image. - * + * Get the final blurred image. * Use can call this function to get the blurred result as an image, to use as they wish. It is not necessary to call this unless you specifically require it. - * @since_tizen 2.4 - * @return A handle on the blurred image, contained in a render target. * @pre The user must call Activate() before the render target will be returned. + * @return A handle on the blurred image, contained in a render target. */ FrameBufferImage GetBlurredRenderTarget() const; /** - * @brief Set background color for the view. The background will be filled with this color. - * @since_tizen 2.4 + * Set background color for the view. The background will be filled with this color. * @param[in] color The background color. */ void SetBackgroundColor( const Vector4& color ); /** - * @brief Get the background color. - * @since_tizen 2.4 + * Get the background color. * @return The background color. */ Vector4 GetBackgroundColor() const; public: // Signals /** - * @brief If ActivateOnce has been called, then connect to this signal to be notified when the + * If ActivateOnce has been called, then connect to this signal to be notified when the * target actor has been rendered. - * @since_tizen 2.4 * @return The Finished signal */ GaussianBlurViewSignal& FinishedSignal(); @@ -299,15 +265,13 @@ public: // Signals public: /** - * @brief Creates a handle using the Toolkit::Internal implementation. - * @since_tizen 2.4 + * Creates a handle using the Toolkit::Internal implementation. * @param[in] implementation The UI Control implementation. */ DALI_INTERNAL GaussianBlurView( Internal::GaussianBlurView& implementation ); /** - * @brief Allows the creation of this UI Control from an Internal::CustomActor pointer. - * @since_tizen 2.4 + * Allows the creation of this UI Control from an Internal::CustomActor pointer. * @param[in] internal A pointer to the internal CustomActor. */ DALI_INTERNAL GaussianBlurView( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/image-view/image-view.h b/dali-toolkit/public-api/controls/image-view/image-view.h index 89861de..fe6d7b1 100644 --- a/dali-toolkit/public-api/controls/image-view/image-view.h +++ b/dali-toolkit/public-api/controls/image-view/image-view.h @@ -32,37 +32,34 @@ namespace Internal DALI_INTERNAL class ImageView; } /** - * @addtogroup dali_toolkit_controls_image_view + * @addtogroup dali-toolkit-controls-image-view * @{ */ /** - * @brief ImageView is a class for displaying an Image. - * @since_tizen 2.4 * + * @brief ImageView is a class for displaying an Image. */ class DALI_IMPORT_API ImageView : public Control { public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices }; /** * @brief An enumeration of properties belonging to the ImageView class. - * @since_tizen 2.4 */ struct Property { enum { - RESOURCE_URL = PROPERTY_START_INDEX, ///< type string @since_tizen 2.4 @see SetImage() + RESOURCE_URL = PROPERTY_START_INDEX, ///< name "resource-url", @see SetImage(), type string }; }; @@ -70,14 +67,12 @@ public: /** * @brief Create an uninitialized ImageView. - * @since_tizen 2.4 */ ImageView(); /** * @brief Create an initialized ImageView. * - * @since_tizen 2.4 * @return A handle to a newly allocated Dali ImageView. */ static ImageView New(); @@ -86,7 +81,6 @@ public: * @brief Create an initialized ImageView from an Image. * * If the handle is empty, ImageView will display nothing - * @since_tizen 2.4 * @param[in] image The Image to display. * @return A handle to a newly allocated ImageView. */ @@ -96,7 +90,6 @@ public: * @brief Create an initialized ImageView from an Image resource url * * If the string is empty, ImageView will display nothing - * @since_tizen 2.4 * @param[in] url The url of the image resource to display. * @return A handle to a newly allocated ImageView. */ @@ -106,14 +99,12 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~ImageView(); /** * @brief Copy constructor. * - * @since_tizen 2.4 * @param[in] imageView ImageView to copy. The copied ImageView will point at the same implementation */ ImageView( const ImageView& imageView ); @@ -121,19 +112,17 @@ public: /** * @brief Assignment operator. * - * @since_tizen 2.4 * @param[in] imageView The ImageView to assign from. * @return The updated ImageView. */ ImageView& operator=( const ImageView& imageView ); /** - * @brief Downcast a handle to ImageView handle. + * @brief Downcast an Object handle to ImageView. * * If handle points to a ImageView the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a ImageView or an uninitialized handle */ @@ -143,7 +132,6 @@ public: * @brief Sets this ImageView from an Image * * If the handle is empty, ImageView will display nothing - * @since_tizen 2.4 * @param[in] image The Image to display. */ void SetImage( Image image ); @@ -151,8 +139,6 @@ public: /** * @brief Gets the Image * - * @since_tizen 2.4 - * @remarks Calls to this method should be avoided as this may return an empty handle if the image has not been created yet. * @return The Image currently set to this ImageView */ Image GetImage() const; @@ -162,7 +148,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The ImageView implementation. */ DALI_INTERNAL ImageView( Internal::ImageView& implementation ); @@ -170,7 +155,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this ImageView from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ DALI_INTERNAL ImageView( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/model3d-view/model3d-view.cpp b/dali-toolkit/public-api/controls/model3d-view/model3d-view.cpp new file mode 100644 index 0000000..e1dc94c --- /dev/null +++ b/dali-toolkit/public-api/controls/model3d-view/model3d-view.cpp @@ -0,0 +1,87 @@ +/* + * Copyright (c) 2015 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +// CLASS HEADER + +#include + +// INTERNAL INCLUDES +#include + +// EXTERNAL INCLUDES + +namespace Dali +{ + +namespace Toolkit +{ + +Model3dView::Model3dView() +{} + +Model3dView::Model3dView( const Model3dView& model3dView ) +: Control( model3dView ) +{ +} + +Model3dView& Model3dView::operator=( const Model3dView& model3dView ) +{ + if( &model3dView != this ) + { + Control::operator=( model3dView ); + } + return *this; +} + +Model3dView::~Model3dView() +{ +} + +Model3dView Model3dView::New() +{ + return Internal::Model3dView::New(); +} + +Model3dView Model3dView::New( const std::string& objUrl, const std::string& mtlUrl, const std::string& imagesUrl ) +{ + Model3dView model3dView = Internal::Model3dView::New(); + model3dView.SetProperty( Model3dView::Property::GEOMETRY_URL, Dali::Property::Value( objUrl ) ); + model3dView.SetProperty( Model3dView::Property::MATERIAL_URL, Dali::Property::Value( mtlUrl ) ); + model3dView.SetProperty( Model3dView::Property::IMAGES_URL, Dali::Property::Value( imagesUrl ) ); + + return model3dView; +} + +Model3dView Model3dView::DownCast( BaseHandle handle ) +{ + return Control::DownCast(handle); +} + +Model3dView::Model3dView( Internal::Model3dView& implementation ) + : Control( implementation ) +{ +} + +Model3dView::Model3dView( Dali::Internal::CustomActor* internal ) + : Control( internal ) +{ + VerifyCustomActorPointer( internal ); +} + +} // namespace Toolkit + +} // namespace Dali diff --git a/dali-toolkit/public-api/controls/model3d-view/model3d-view.h b/dali-toolkit/public-api/controls/model3d-view/model3d-view.h new file mode 100644 index 0000000..4615a8b --- /dev/null +++ b/dali-toolkit/public-api/controls/model3d-view/model3d-view.h @@ -0,0 +1,186 @@ +#ifndef __DALI_TOOLKIT_MODEL3D_VIEW_H__ +#define __DALI_TOOLKIT_MODEL3D_VIEW_H__ + +/* + * Copyright (c) 2015 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +// INTERNAL INCLUDES +#include + +namespace Dali +{ + +namespace Toolkit +{ + +namespace Internal DALI_INTERNAL +{ +class Model3dView; +} + +/** + * @brief Model3dView is a control for displaying 3d geometry. + * + * @details All the geometry loaded with the control is automatically centered and scaled to fit the size of all the other controls. + * So the max is (0.5,0.5) and the min is (-0.5,-0.5) + + * @since_tizen 2.4 +*/ +class DALI_IMPORT_API Model3dView : public Control +{ +public: + + /** + * @brief The start and end property ranges for this control. + * + * @since_tizen 2.4 + */ + enum PropertyRange + { + PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000, ///< Reserve property indices + + ANIMATABLE_PROPERTY_START_INDEX = ANIMATABLE_PROPERTY_REGISTRATION_START_INDEX, + ANIMATABLE_PROPERTY_END_INDEX = ANIMATABLE_PROPERTY_REGISTRATION_START_INDEX + 1000 ///< Reserve animatable property indices + }; + + /** + * @brief An enumeration of properties belonging to the TextLabel class. + * + * @since_tizen 2.4 + */ + struct Property + { + enum + { + GEOMETRY_URL = PROPERTY_START_INDEX, ///< name "geometry-url", The path to the geometry file, type STRING + MATERIAL_URL, ///< name "material-url", The path to the material file, type STRING + IMAGES_URL, ///< name "images-url", The path to the images directory, type STRING + ILLUMINATION_TYPE, ///< name "illumination-type", The type of illumination, type INTEGER + TEXTURE0_URL, ///< name "texture0-url", The path to first texture, type STRING + TEXTURE1_URL, ///< name "texture1-url", The path to second texture, type STRING + TEXTURE2_URL, ///< name "texture2-url", The path to third texture, type STRING + + LIGHT_POSITION = ANIMATABLE_PROPERTY_START_INDEX ///< name "light-position", The coordinates of the light, type Vector3 + }; + }; + + /** + * @brief Type for illumination + * + * @since_tizen 2.4 + */ + enum IlluminationType + { + DIFFUSE, + DIFFUSE_WITH_TEXTURE, + DIFFUSE_WITH_NORMAL_MAP + }; + + + /** + * @brief Create a new instance of a Model3dView control. + * + * @since_tizen 2.4 + * @return A handle to the new Model3dView control. + */ + static Model3dView New(); + + /** + * @brief Create a new instance of a Model3dView control. + * + * @since_tizen 2.4 + * @param[in] objUrl OBJ file name + * @param[in] mtlUrl Material file name + * @param[in] imagesUrl Texture image file name + * @return A handle to the new Model3dView control. + */ + static Model3dView New( const std::string& objUrl, const std::string& mtlUrl, const std::string& imagesUrl ); + + + /** + * @brief Create an uninitialized Model3dView + * + * @details Only derived versions can be instantiated. + * Calling member functions with an uninitialized Dali::Object is not allowed. + * + * @since_tizen 2.4 + */ + Model3dView(); + + /** + * @brief Destructor + * + * @details This is non-virtual since derived Handle types must not contain data or virtual methods. + * + * @since_tizen 2.4 + */ + ~Model3dView(); + + /** + * @brief Copy constructor. + * + * @since_tizen 2.4 + * @param[in] model3dView Handle to copy + */ + Model3dView( const Model3dView& model3dView ); + + /** + * @brief Assignment operator. + * + * @since_tizen 2.4 + * @param[in] model3dView Handle to assign + */ + Model3dView& operator=( const Model3dView& model3dView ); + + /** + * @brief Downcast an Object handle to Model3dView. + * + * @details If handle points to a Model3dView the downcast produces valid handle. + * If not the returned handle is left uninitialized. + * + * @since_tizen 2.4 + * @param[in] handle Handle to an object + * @return handle to a Model3dView or an uninitialized handle + */ + static Model3dView DownCast( BaseHandle handle ); + +public: // Not intended for application developers + + /** + * @brief Creates a handle using the Toolkit::Internal implementation. + * + * @since_tizen 2.4 + * @param[in] implementation The Control implementation. + */ + DALI_INTERNAL Model3dView( Internal::Model3dView& implementation ); + + /** + * @brief Allows the creation of this Control from an Internal::CustomActor pointer. + * + * @since_tizen 2.4 + * @param[in] internal A pointer to the internal CustomActor. + */ + DALI_INTERNAL Model3dView( Dali::Internal::CustomActor* internal ); + +}; + +} // namespace Toolkit + +} // namespace Dali + +#endif // __DALI_TOOLKIT_MODEL3D_VIEW_H__ diff --git a/dali-toolkit/public-api/controls/scroll-bar/scroll-bar.h b/dali-toolkit/public-api/controls/scroll-bar/scroll-bar.h index b67b744..3f1ad10 100755 --- a/dali-toolkit/public-api/controls/scroll-bar/scroll-bar.h +++ b/dali-toolkit/public-api/controls/scroll-bar/scroll-bar.h @@ -34,15 +34,19 @@ namespace Internal DALI_INTERNAL class ScrollBar; } /** - * @addtogroup dali_toolkit_controls_scroll_bar + * @addtogroup dali-toolkit-controls-scroll-bar * @{ */ /** - * @brief ScrollBar is a UI component that can be linked to the scrollable objects + * ScrollBar is a UI component that can be linked to the scrollable objects * indicating the current scroll position of the scrollable object. * - * @since_tizen 2.4 + * Signals + * | %Signal Name | Method | + * |----------------------------------|--------------------------------------------| + * | pan-finished | @ref PanFinishedSignal() | + * | scroll-position-interval-reached | @ref ScrollPositionIntervalReachedSignal() | */ class DALI_IMPORT_API ScrollBar : public Control { @@ -52,74 +56,67 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices }; /** * @brief An enumeration of properties belonging to the ScrollBar class. - * @since_tizen 2.4 */ struct Property { enum { - SCROLL_DIRECTION = PROPERTY_START_INDEX, ///< type std::string @since_tizen 2.4 @see SetScrollDirection() - INDICATOR_HEIGHT_POLICY, ///< type std::string @since_tizen 2.4 @see SetIndicatorHeightPolicy() - INDICATOR_FIXED_HEIGHT, ///< type float @since_tizen 2.4 @see SetIndicatorFixedHeight() - INDICATOR_SHOW_DURATION, ///< type float @since_tizen 2.4 @see SetIndicatorShowDuration() - INDICATOR_HIDE_DURATION, ///< type float @since_tizen 2.4 @see SetIndicatorHideDuration() - SCROLL_POSITION_INTERVALS ///< type Property::Array @since_tizen 2.4 @see SetScrollPositionIntervals() + SCROLL_DIRECTION = PROPERTY_START_INDEX, ///< name "scroll-direction", @see SetScrollDirection(), type std::string + INDICATOR_HEIGHT_POLICY, ///< name "indicator-height-policy", @see SetIndicatorHeightPolicy(), type std::string + INDICATOR_FIXED_HEIGHT, ///< name "indicator-fixed-height", @see SetIndicatorFixedHeight(), type float + INDICATOR_SHOW_DURATION, ///< name "indicator-show-duration", @see SetIndicatorShowDuration(), type float + INDICATOR_HIDE_DURATION, ///< name "indicator-hide-duration", @see SetIndicatorHideDuration(), type float + SCROLL_POSITION_INTERVALS ///< name "scroll-position-intervals",@see SetScrollPositionIntervals() type Property::Array }; }; // Signals - typedef Signal< void () > PanFinishedSignalType; ///< Pan finished signal type @since_tizen 2.4 - typedef Signal< void ( float ) > ScrollPositionIntervalReachedSignalType; ///< Scroll position interval reached signal type @since_tizen 2.4 + typedef Signal< void () > PanFinishedSignalType; + typedef Signal< void ( float ) > ScrollPositionIntervalReachedSignalType; public: /** * @brief Direction. - * @since_tizen 2.4 */ enum Direction { - Vertical = 0, ///< Scroll in the vertical direction @since_tizen 2.4 - Horizontal ///< Scroll in the horizontal direction @since_tizen 2.4 + Vertical = 0, ///< Scroll in the vertical direction + Horizontal ///< Scroll in the horizontal direction }; /** * @brief Indicator height policy. - * @since_tizen 2.4 */ enum IndicatorHeightPolicy { - Variable = 0, ///< Variable height changed dynamically according to the length of scroll content @since_tizen 2.4 - Fixed ///< Fixed height regardless of the length of scroll content @since_tizen 2.4 + Variable = 0, ///< Variable height changed dynamically according to the length of scroll content + Fixed ///< Fixed height regardless of the length of scroll content }; /** * @brief Create an uninitialized ScrollBar; this can be initialized with ScrollBar::New() * Calling member functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ ScrollBar(); /** * @brief Copy constructor. - * @since_tizen 2.4 */ ScrollBar( const ScrollBar& scrollBar ); /** * @brief Assignment operator. - * @since_tizen 2.4 */ ScrollBar& operator=( const ScrollBar& scrollBar ); @@ -127,24 +124,19 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~ScrollBar(); /** * @brief Create an initialized ScrollBar - * @since_tizen 2.4 * @param[in] direction The direction of scroll bar (either vertically or horizontally). * @return A pointer to the created ScrollBar. */ static ScrollBar New(Direction direction = Vertical); /** - * @brief Downcast a handle to ScrollBar handle. - * - * If handle points to a ScrollBar the + * @brief Downcast an Object handle to ScrollBar. If handle points to a ScrollBar the * downcast produces valid handle. If not the returned handle is left uninitialized. - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a ScrollBar or an uninitialized handle */ @@ -155,7 +147,6 @@ public: * * * @pre The handle to the object owing the scroll properties has been initialised and the property index must be vaild. * - * @since_tizen 2.4 * @param[in] handle The handle of the object owing the scroll properties. * @param[in] propertyScrollPosition The index of the scroll position property (The scroll position, type float). * @param[in] propertyMinScrollPosition The index of the minimum scroll position property (The minimum scroll position, type float). @@ -167,20 +158,18 @@ public: /** * @brief Sets the indicator of scroll bar. * - * @since_tizen 2.4 - * @param[in] indicator The indicator that moves to indicate the current scroll position. * @pre The scroll bar actor has been initialised. * + * @param[in] indicator The indicator that moves to indicate the current scroll position. */ void SetScrollIndicator( Actor indicator ); /** * @brief Gets the indicator of scroll bar. * - * @since_tizen 2.4 - * @return The indicator indicates the current scroll position of the scrollable content. * @pre The scroll bar actor has been initialised. * + * @return The indicator indicates the current scroll position of the scrollable content. */ Actor GetScrollIndicator(); @@ -188,10 +177,9 @@ public: * @brief Sets the list of values to get notification when the current scroll position of the scrollable * object goes above or below any of these values. * - * @since_tizen 2.4 - * @param[in] positions List of values to receive notifications for when the current scroll position crosses them * @pre The scroll bar actor has been initialised. * + * @param[in] positions List of values to receive notifications for when the current scroll position crosses them */ void SetScrollPositionIntervals( const Dali::Vector& positions ); @@ -199,27 +187,24 @@ public: * @brief Gets the list of values to receive notifications when the current scroll position of the scrollable * object goes above or below any of these values. * - * @since_tizen 2.4 - * @return The list of values to receive notifications for when the current scroll position crosses them * @pre The scroll bar actor has been initialised. * + * @return The list of values to receive notifications for when the current scroll position crosses them */ Dali::Vector GetScrollPositionIntervals() const; /** * @brief Sets the direction of scroll bar to scroll either vertically or horizontally. * - * @since_tizen 2.4 - * @param[in] direction The direction of scroll bar (either vertically or horizontally). * @pre The scroll bar actor has been initialised. * + * @param[in] direction The direction of scroll bar (either vertically or horizontally). */ void SetScrollDirection( Direction direction ); /** * @brief Gets the direction of scroll bar. * - * @since_tizen 2.4 * @return The direction of scroll bar. */ Direction GetScrollDirection() const; @@ -227,38 +212,33 @@ public: /** * @brief Sets the height policy of scroll indicator to have either variable or fixed height. * - * @since_tizen 2.4 - * @param[in] policy The height policy of scroll indicator * @pre The scroll bar actor has been initialised. * + * @param[in] policy The height policy of scroll indicator */ void SetIndicatorHeightPolicy( IndicatorHeightPolicy policy ); /** * @brief Gets the height policy of scroll indicator. * - * @since_tizen 2.4 * @return The height policy of scroll indicator */ IndicatorHeightPolicy GetIndicatorHeightPolicy() const; /** * @brief Sets the fixed height of scroll indicator. - * * Normally the height of scroll indicator is changed dynamically according to the length of scroll content. * However, when the height policy of scroll indicator is set to be fixed, the height will keep fixed * regardless of the length of scroll content. * - * @since_tizen 2.4 - * @param[in] height The fixed height of the scroll indicator * @pre The scroll bar actor has been initialised. * + * @param[in] height The fixed height of the scroll indicator */ void SetIndicatorFixedHeight( float height ); /** * @brief Gets the fix height of scroll indicator. - * @since_tizen 2.4 * @return The fixed height of the scroll indicator */ float GetIndicatorFixedHeight() const; @@ -266,16 +246,14 @@ public: /** * @brief Sets the duration in second for the scroll indicator to become fully visible * - * @since_tizen 2.4 - * @param[in] durationSeconds The duration for the scroll indicator to become fully visible * @pre The scroll bar actor has been initialised; durationSeconds must be zero or greater; zero means the indicator will be shown instantly. * + * @param[in] durationSeconds The duration for the scroll indicator to become fully visible */ void SetIndicatorShowDuration( float durationSeconds ); /** * @brief Gets the duration in second for the scroll indicator to become fully visible - * @since_tizen 2.4 * @return The duration for the scroll indicator to become fully visible */ float GetIndicatorShowDuration() const; @@ -283,29 +261,25 @@ public: /** * @brief Sets the duration in second for the scroll indicator to become fully invisible * - * @since_tizen 2.4 - * @param[in] durationSeconds The duration for the scroll indicator to become fully invisible * @pre The scroll bar actor has been initialised; durationSeconds must be zero or greater; zero means the indicator will be hidden instantly. * + * @param[in] durationSeconds The duration for the scroll indicator to become fully invisible */ void SetIndicatorHideDuration( float durationSeconds ); /** * @brief Gets the duration in second for the scroll indicator to become fully invisible - * @since_tizen 2.4 * @return The duration for the scroll indicator to become fully invisible */ float GetIndicatorHideDuration() const; /** * @brief Shows the scroll indicator - * @since_tizen 2.4 */ void ShowIndicator(); /** * @brief Hides the scroll indicator - * @since_tizen 2.4 */ void HideIndicator(); @@ -313,47 +287,41 @@ public: // Signals /** * @brief Signal emitted when panning is finished on the scroll indicator. - * * Signal only emitted when the source of the scroll position properties are set. * * A callback of the following type may be connected: * @code * void YourCallbackName(); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ ScrollBar::PanFinishedSignalType& PanFinishedSignal(); /** * @brief Signal emitted when the current scroll position of the scrollable content * goes above or below the values specified by SCROLL_POSITION_INTERVALS property. - * * Signal only emitted when the source of the scroll position properties are set. * * A callback of the following type may be connected: * @code * void YourCallbackName(float currentScrollPosition); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ ScrollBar::ScrollPositionIntervalReachedSignalType& ScrollPositionIntervalReachedSignal(); public: // Not intended for application developers /** - * @brief Creates a handle using the Toolkit::Internal implementation. - * @since_tizen 2.4 + * Creates a handle using the Toolkit::Internal implementation. * @param[in] implementation The Control implementation. */ DALI_INTERNAL ScrollBar( Internal::ScrollBar& implementation ); /** - * @brief Allows the creation of this Control from an Internal::CustomActor pointer. - * @since_tizen 2.4 + * Allows the creation of this Control from an Internal::CustomActor pointer. * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL ScrollBar( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/scrollable/item-view/default-item-layout.h b/dali-toolkit/public-api/controls/scrollable/item-view/default-item-layout.h index 93bd192..8299d84 100644 --- a/dali-toolkit/public-api/controls/scrollable/item-view/default-item-layout.h +++ b/dali-toolkit/public-api/controls/scrollable/item-view/default-item-layout.h @@ -27,29 +27,24 @@ namespace Dali namespace Toolkit { /** - * @addtogroup dali_toolkit_controls_item_view + * @addtogroup dali-toolkit-controls-item-view * @{ */ -/** - * @brief Default item layout mode. - * @since_tizen 2.4 - */ namespace DefaultItemLayout { enum Type { - DEPTH, ///< Items arranged in a grid, scrolling along the Z-Axis. @since_tizen 2.4 - GRID, ///< Items arranged in a grid, scrolling along the Y-Axis. @since_tizen 2.4 - LIST, ///< One item per line, scrolling along the Y-Axis. @since_tizen 2.4 - SPIRAL ///< Items arranged in a spiral, centered around the Y-Axis. @since_tizen 2.4 + DEPTH, ///< Items arranged in a grid, scrolling along the Z-Axis. + GRID, ///< Items arranged in a grid, scrolling along the Y-Axis. + LIST, ///< One item per line, scrolling along the Y-Axis. + SPIRAL ///< Items arranged in a spiral, centered around the Y-Axis. }; /** * @brief Creates a built-in default item-layout * - * @since_tizen 2.4 * @param[in] type The type of layout required. * * @return An ItemLayoutPtr to the newly created layout. diff --git a/dali-toolkit/public-api/controls/scrollable/item-view/item-factory.h b/dali-toolkit/public-api/controls/scrollable/item-view/item-factory.h index 6f59ae3..84ef7b7 100644 --- a/dali-toolkit/public-api/controls/scrollable/item-view/item-factory.h +++ b/dali-toolkit/public-api/controls/scrollable/item-view/item-factory.h @@ -27,15 +27,13 @@ namespace Dali namespace Toolkit { /** - * @addtogroup dali_toolkit_controls_item_view + * @addtogroup dali-toolkit-controls-item-view * @{ */ /** * @brief ItemFactory is for providing actors to ItemView. - * * Each actor is identified by a unique ID, and has a linear order from 0 to GetNumberOfItems()-1. - * @since_tizen 2.4 */ class ItemFactory { @@ -45,7 +43,6 @@ public: /** * @brief Virtual destructor. - * @since_tizen 2.4 */ DALI_EXPORT_API virtual ~ItemFactory() {}; @@ -53,7 +50,6 @@ public: * @brief Query the number of items available from the factory. * * The maximum available item has an ID of GetNumberOfItems() - 1. - * @since_tizen 2.4 * @return the number of items */ virtual unsigned int GetNumberOfItems() = 0; @@ -61,7 +57,6 @@ public: /** * @brief Create an Actor to represent a visible item. * - * @since_tizen 2.4 * @param[in] itemId The ID of the newly visible item. * @return An actor, or an uninitialized pointer if the ID is out of range. */ @@ -70,16 +65,14 @@ public: /** * @brief Notify the factory the actor representing the item is removed from ItemView. * - * @since_tizen 2.4 * @param[in] itemId The ID of the released item. * @param[in] actor The actor that represents the released item. */ virtual void ItemReleased(unsigned int itemId, Actor actor) {}; /** - * @brief Retrieve the extension for this control + * Retrieve the extension for this control * - * @since_tizen 2.4 * @return The extension if available, NULL otherwise */ virtual Extension* GetExtension() diff --git a/dali-toolkit/public-api/controls/scrollable/item-view/item-layout.h b/dali-toolkit/public-api/controls/scrollable/item-view/item-layout.h index c93a61d..9302e8a 100644 --- a/dali-toolkit/public-api/controls/scrollable/item-view/item-layout.h +++ b/dali-toolkit/public-api/controls/scrollable/item-view/item-layout.h @@ -31,24 +31,22 @@ namespace Dali namespace Toolkit { /** - * @addtogroup dali_toolkit_controls_item_view + * @addtogroup dali-toolkit-controls-item-view * @{ */ class ItemLayout; -typedef IntrusivePtr ItemLayoutPtr; ///< Pointer to ItemLayout object @since_tizen 2.4 +typedef IntrusivePtr ItemLayoutPtr; ///< Pointer to a Dali::Toolkit::ItemLayout object /** * @brief A support class for managing ranges of items. - * @since_tizen 2.4 */ struct ItemRange { /** * @brief Create a range of item identifiers. * - * @since_tizen 2.4 * @param[in] beginItem The first item within the range. * @param[in] endItem The past-the-end item. */ @@ -61,7 +59,6 @@ struct ItemRange /** * @brief Copy Constructor. * - * @since_tizen 2.4 * @param[in] copy ItemRange we should copy from. */ ItemRange(const ItemRange& copy) @@ -73,7 +70,6 @@ struct ItemRange /** * @brief Assignment operator. * - * @since_tizen 2.4 * @param[in] range The Range to assign from. * @return The updated range. */ @@ -87,7 +83,6 @@ struct ItemRange /** * @brief Test whether an item is within the range. * - * @since_tizen 2.4 * @param[in] itemId The item identifier. * @return True if the item is within the range. */ @@ -100,7 +95,6 @@ struct ItemRange /** * @brief Create the intersection of two ranges. * - * @since_tizen 2.4 * @param[in] second The second range. * @return The intersection. */ @@ -131,7 +125,6 @@ struct ItemRange * * An ItemLayout also describes the direction of input gestures, used to scroll through the layout. * Whilst scrolling, the layout provides a range of items that are within a layout-area (3D bounding volume). - * @since_tizen 2.4 */ class DALI_IMPORT_API ItemLayout : public RefObject { @@ -141,14 +134,12 @@ public: /** * @brief Virtual destructor. - * @since_tizen 2.4 */ DALI_IMPORT_API virtual ~ItemLayout(); /** * @brief Set the orientation of the layout. * - * @since_tizen 2.4 * @param[in] orientation The orientation of the layout. */ DALI_IMPORT_API void SetOrientation(ControlOrientation::Type orientation); @@ -156,7 +147,6 @@ public: /** * @brief Query the orientation of the layout. * - * @since_tizen 2.4 * @return the orientation of the layout. */ DALI_IMPORT_API ControlOrientation::Type GetOrientation() const; @@ -166,19 +156,17 @@ public: * * This will return the default size for the layout unless overridden by calling SetItemSize(). * - * @since_tizen 2.4 + * @note layout-position is not provided as a parameter, since applying size constraints is not recommended. + * Animating to target-sizes is preferable, since this allows controls to perform layouting without constraints. * @param[in] itemId The ID of an item in the layout. * @param[in] layoutSize The layout size * @param[out] itemSize The target size of an item. - * @note layout-position is not provided as a parameter, since applying size constraints is not recommended. - * Animating to target-sizes is preferable, since this allows controls to perform layouting without constraints. */ DALI_IMPORT_API void GetItemSize( unsigned int itemId, const Vector3& layoutSize, Vector3& itemSize ) const; /** * @brief Overrides the default size for the layout. * - * @since_tizen 2.4 * @param[in] itemSize The size of each item. */ DALI_IMPORT_API void SetItemSize( const Vector3& itemSize ); @@ -187,7 +175,6 @@ public: * @brief Query the minimum valid layout position; this is a negative value. * * When scrolling, the first item will move within the range 0 to GetMinimumLayoutPosition(). - * @since_tizen 2.4 * @param[in] numberOfItems The current number of items in the layout. * @param[in] layoutSize The size of the layout area. * @return The minimum layout position. @@ -199,7 +186,6 @@ public: * * This anchor position is the position where all the items in the layout are aligned to * their rounded layout positions in integer. - * @since_tizen 2.4 * @param[in] layoutPosition The layout position. * @return The closest anchor position for the given layout position. */ @@ -209,7 +195,6 @@ public: * @brief Query the layout position for the first item in the layout to move to when the layout * needs to scroll to a particular item. * - * @since_tizen 2.4 * @param[in] itemId The ID of an item in the layout. * @return The layout position for the first item in the layout to move to. */ @@ -218,7 +203,6 @@ public: /** * @brief Query the items within a given layout-area. * - * @since_tizen 2.4 * @param[in] firstItemPosition The layout-position of the first item in the layout. * @param[in] layoutSize The size of the layout area. * @return The ID of the first & last visible item. @@ -236,7 +220,6 @@ public: * implementations should provide their own version of this function * to ensure proper functionality of internal toolkit systems. * - * @since_tizen 2.4 * @param[in] itemID id of the item to bring within the viewable screen area * @param[in] currentLayoutPosition the current layout position of the item view instance * @param[in] layoutSize the current size of the item view instance @@ -247,7 +230,6 @@ public: /** * @brief Query the number of items that should be reserved, for scrolling purposes. * - * @since_tizen 2.4 * @param[in] layoutSize The size of the layout area. * @return The number of extra items. ItemView will populate itself with actors within the layout-area * (see GetItemsWithinArea), plus this number of additional items on either-side. @@ -257,12 +239,11 @@ public: /** * @brief Retrieve the default size of an item in the layout. * - * @since_tizen 2.4 + * @note layout-position is not provided as a parameter, since applying size constraints is not recommended. + * Animating to target-sizes is preferable, since this allows controls to perform layouting without constraints. * @param[in] itemId The ID of an item in the layout. * @param[in] layoutSize The layout size * @param[out] itemSize The target size of an item. - * @note layout-position is not provided as a parameter, since applying size constraints is not recommended. - * Animating to target-sizes is preferable, since this allows controls to perform layouting without constraints. */ virtual void GetDefaultItemSize( unsigned int itemId, const Vector3& layoutSize, Vector3& itemSize ) const = 0; @@ -271,7 +252,6 @@ public: * * When an input gesture follows this direction, the layout-position of items will be increased. * If the input gesture points in the opposite direction, then the layout-positions will decrease. - * @since_tizen 2.4 * @return The scroll direction in degrees. */ virtual Degree GetScrollDirection() const = 0; @@ -286,7 +266,6 @@ public: * position of actors will be moved by 1. * Therefore, the bigger the factor is, the faster the scroll speed will be. * - * @since_tizen 2.4 * @return The scroll speed factor of the layout. */ virtual float GetScrollSpeedFactor() const = 0; @@ -295,7 +274,6 @@ public: * @brief Query the maximum swipe speed in pixels per second. * * Swipe gestures will be clamped when exceeding this speed limit. - * @since_tizen 2.4 * @return speed The maximum swipe speed. */ virtual float GetMaximumSwipeSpeed() const = 0; @@ -306,7 +284,6 @@ public: * This is the time taken to animate each * item to its next layout position (e.g. from 1.0 to 2.0) when a flick animation is triggered * by a swipe gesture. - * @since_tizen 2.4 * @return The duration of the flick animation. */ virtual float GetItemFlickAnimationDuration() const = 0; @@ -314,7 +291,6 @@ public: /** * @brief Gets the id of the next item for KeyboardFocusManager to focus on depending on the inputted item ID. * - * @since_tizen 2.4 * @param[in] itemID The current focused item * @param[in] maxItems The maximum number of items in the list * @param[in] direction The directional key pressed on the keyboard @@ -333,7 +309,6 @@ public: * position of actors will be moved by 1. * Therefore, the bigger the factor is, the faster the flick speed will be. * - * @since_tizen 2.4 * @return The scroll speed factor of the layout. */ DALI_IMPORT_API virtual float GetFlickSpeedFactor() const; @@ -351,7 +326,6 @@ public: /** * @brief Gets the position of a given item * - * @since_tizen 2.4 * @param[in] itemID id of the item we want to get its position * @param[in] currentLayoutPosition the current layout position of the item view instance * @param[in] layoutSize the current size of the item view instance @@ -360,9 +334,8 @@ public: DALI_IMPORT_API virtual Vector3 GetItemPosition(int itemID, float currentLayoutPosition, const Vector3& layoutSize) const = 0; /** - * @brief Retrieve the extension for this layout. + * Retrieve the extension for this layout. * - * @since_tizen 2.4 * @return The extension if available, NULL otherwise */ virtual Extension* GetExtension() @@ -374,21 +347,18 @@ protected: /** * @brief Create a new ItemLayout; Only derived versions are instantiatable. - * @since_tizen 2.4 */ DALI_IMPORT_API ItemLayout(); private: /** - * @brief Don't allow copy constructor - * @since_tizen 2.4 + * Don't allow copy constructor */ ItemLayout( const ItemLayout& handle ); /** - * @brief Don't allow copy operator - * @since_tizen 2.4 + * Don't allow copy operator */ ItemLayout& operator=( const ItemLayout& handle ); diff --git a/dali-toolkit/public-api/controls/scrollable/item-view/item-view-declarations.h b/dali-toolkit/public-api/controls/scrollable/item-view/item-view-declarations.h index f67ff54..7388bfa 100644 --- a/dali-toolkit/public-api/controls/scrollable/item-view/item-view-declarations.h +++ b/dali-toolkit/public-api/controls/scrollable/item-view/item-view-declarations.h @@ -29,21 +29,21 @@ namespace Dali namespace Toolkit { /** - * @addtogroup dali_toolkit_controls_item_view + * @addtogroup dali-toolkit-controls-item-view * @{ */ -typedef unsigned int ItemId; ///< Unique identity for each item in the view. @since_tizen 2.4 +typedef unsigned int ItemId; ///< Unique identity for each item in the view. -typedef std::vector ItemIdContainer; ///< Item id container type @since_tizen 2.4 -typedef ItemIdContainer::iterator ItemIdIter; ///< Item id iterator type @since_tizen 2.4 -typedef ItemIdContainer::const_iterator ConstItemIdIter; ///< Item id const iterator type @since_tizen 2.4 +typedef std::vector ItemIdContainer; +typedef ItemIdContainer::iterator ItemIdIter; +typedef ItemIdContainer::const_iterator ConstItemIdIter; -typedef std::pair Item; ///< Item type @since_tizen 2.4 +typedef std::pair Item; -typedef std::vector ItemContainer; ///< Item container type @since_tizen 2.4 -typedef ItemContainer::iterator ItemIter; ///< Item iterator type @since_tizen 2.4 -typedef ItemContainer::const_iterator ConstItemIter; ///< Item const iterator type @since_tizen 2.4 +typedef std::vector ItemContainer; +typedef ItemContainer::iterator ItemIter; +typedef ItemContainer::const_iterator ConstItemIter; class ItemView; class ItemLayout; diff --git a/dali-toolkit/public-api/controls/scrollable/item-view/item-view.h b/dali-toolkit/public-api/controls/scrollable/item-view/item-view.h index 5f5df80..2790194 100644 --- a/dali-toolkit/public-api/controls/scrollable/item-view/item-view.h +++ b/dali-toolkit/public-api/controls/scrollable/item-view/item-view.h @@ -35,7 +35,7 @@ namespace Internal DALI_INTERNAL class ItemView; } /** - * @addtogroup dali_toolkit_controls_item_view + * @addtogroup dali-toolkit-controls-item-view * @{ */ @@ -43,7 +43,7 @@ class ItemFactory; class ItemLayout; struct ItemRange; -typedef IntrusivePtr ItemLayoutPtr; ///< Pointer to ItemLayout object @since_tizen 2.4 +typedef IntrusivePtr ItemLayoutPtr; /** * @brief ItemView is a scrollable layout container. @@ -51,43 +51,41 @@ typedef IntrusivePtr ItemLayoutPtr; ///< Pointer to ItemLayout objec * Multiple ItemLayouts may be provided, to determine the logical position of each item a layout. * Actors are provided from an external ItemFactory, to display the currently visible items. * - * @since_tizen 2.4 + * Signals + * | %Signal Name | Method | + * |----------------------------------|--------------------------------------------| + * | layout-activated | @ref LayoutActivatedSignal() | */ class DALI_IMPORT_API ItemView : public Scrollable { public: - /** - * @brief The start and end property ranges for this control. - * @since_tizen 2.4 - */ enum PropertyRange { ANIMATABLE_PROPERTY_START_INDEX = Toolkit::Scrollable::ANIMATABLE_PROPERTY_END_INDEX + 1, - ANIMATABLE_PROPERTY_END_INDEX = ANIMATABLE_PROPERTY_START_INDEX + 1000 ///< Reserve animatable property indices @since_tizen 2.4 + ANIMATABLE_PROPERTY_END_INDEX = ANIMATABLE_PROPERTY_START_INDEX + 1000 ///< Reserve animatable property indices }; /** * @brief An enumeration of properties belonging to the ScrollView class. - * @since_tizen 2.4 */ struct Property { enum { - LAYOUT_POSITION = ANIMATABLE_PROPERTY_START_INDEX, ///< Property, name "layout-position", type float @since_tizen 2.4 - SCROLL_SPEED, ///< Property, name "scroll-speed", type float @since_tizen 2.4 - OVERSHOOT, ///< Property, name "overshoot", type float @since_tizen 2.4 - SCROLL_DIRECTION, ///< Property, name "scroll-direction", type Vector2 @since_tizen 2.4 - LAYOUT_ORIENTATION, ///< Property, name "layout-orientation", type integer @since_tizen 2.4 - SCROLL_CONTENT_SIZE ///< Property, name "scroll-content-size", type float @since_tizen 2.4 + LAYOUT_POSITION = ANIMATABLE_PROPERTY_START_INDEX, ///< Property, name "layout-position", type float + SCROLL_SPEED, ///< Property, name "scroll-speed", type float + OVERSHOOT, ///< Property, name "overshoot", type float + SCROLL_DIRECTION, ///< Property, name "scroll-direction", type Vector2 + LAYOUT_ORIENTATION, ///< Property, name "layout-orientation", type integer + SCROLL_CONTENT_SIZE ///< Property, name "scroll-content-size", type float }; }; // Signals - typedef Signal< void () > LayoutActivatedSignalType; ///< Layout activated signal type @since_tizen 2.4 + typedef Signal< void () > LayoutActivatedSignalType; public: @@ -95,19 +93,16 @@ public: * @brief Create an uninitialized ItemView; this can be initialized with ItemView::New(). * * Calling member functions with an uninitialized Dali::Object is not allowed. - * @since_tizen 2.4 */ ItemView(); /** * @brief Copy constructor. - * @since_tizen 2.4 */ ItemView( const ItemView& itemView ); /** * @brief Assignment operator. - * @since_tizen 2.4 */ ItemView& operator=( const ItemView& itemView ); @@ -115,26 +110,23 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~ItemView(); /** * @brief Create an initialized ItemView. * - * @since_tizen 2.4 * @param[in] factory The factory which provides ItemView with items. * @return A handle to a newly allocated Dali resource. */ static ItemView New(ItemFactory& factory); /** - * @brief Downcast a handle to ItemView handle. + * @brief Downcast an Object handle to ItemView. * * If handle points to a ItemView the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a ItemView or an uninitialized handle */ @@ -143,7 +135,6 @@ public: /** * @brief Query the number of layouts. * - * @since_tizen 2.4 * @return The number of layouts. */ unsigned int GetLayoutCount() const; @@ -151,7 +142,6 @@ public: /** * @brief Add a layout. * - * @since_tizen 2.4 * @param[in] layout The layout. */ void AddLayout(ItemLayout& layout); @@ -159,26 +149,23 @@ public: /** * @brief Remove a layout. * - * @since_tizen 2.4 - * @param[in] layoutIndex The index of one of the ItemView layouts. * @pre layoutIndex is less than GetLayoutCount(). + * @param[in] layoutIndex The index of one of the ItemView layouts. */ void RemoveLayout(unsigned int layoutIndex); /** * @brief Retrieve a layout. * - * @since_tizen 2.4 + * @pre layoutIndex is less than GetLayoutCount(). * @param[in] layoutIndex The index of the layout to retrieve. * @return The layout - * @pre layoutIndex is less than GetLayoutCount(). */ ItemLayoutPtr GetLayout(unsigned int layoutIndex) const; /** * @brief Retrieve the currently active layout, if any. * - * @since_tizen 2.4 * @return The layout, or an uninitialized pointer if no layout is active. */ ItemLayoutPtr GetActiveLayout() const; @@ -186,7 +173,6 @@ public: /** * @brief Retrieve the current layout-position of an item in the ItemView. * - * @since_tizen 2.4 * @param[in] itemId The item identifier. * @return The current layout-position. */ @@ -199,12 +185,11 @@ public: * This is done by applying constraints from the new layout, and * removing constraints from the previous layout. * - * @since_tizen 2.4 + * @pre layoutIndex is less than GetLayoutCount(). + * @pre durationSeconds is greater or equal to zero. * @param[in] layoutIndex The index of one of the ItemView layouts. * @param[in] targetSize The target ItemView & layout size. * @param[in] durationSeconds The time taken to relayout in seconds (zero for immediate). - * @pre layoutIndex is less than GetLayoutCount(). - * @pre durationSeconds is greater or equal to zero. */ void ActivateLayout(unsigned int layoutIndex, Vector3 targetSize, float durationSeconds); @@ -212,7 +197,6 @@ public: * @brief Deactivate the current layout, if any. * * The constraints applied by the layout will be removed. - * @since_tizen 2.4 */ void DeactivateCurrentLayout(); @@ -220,7 +204,6 @@ public: * @brief Set the minimum swipe speed in pixels per second; A pan * gesture must exceed this to trigger a swipe. * - * @since_tizen 2.4 * @param[in] speed The minimum swipe speed */ void SetMinimumSwipeSpeed(float speed); @@ -228,7 +211,6 @@ public: /** * @brief Get the minimum swipe speed in pixels per second. * - * @since_tizen 2.4 * @return The minimum swipe speed */ float GetMinimumSwipeSpeed() const; @@ -237,7 +219,6 @@ public: * @brief Set the minimum swipe distance in actor coordinates; A pan * gesture must exceed this to trigger a swipe. * - * @since_tizen 2.4 * @param[in] distance The minimum swipe distance. */ void SetMinimumSwipeDistance(float distance); @@ -245,7 +226,6 @@ public: /** * @brief Get the minimum swipe distance in actor coordinates. * - * @since_tizen 2.4 * @return The minimum swipe distance */ float GetMinimumSwipeDistance() const; @@ -253,7 +233,6 @@ public: /** * @brief Set the step of scroll distance in actor coordinates for each wheel event received. * - * @since_tizen 2.4 * @param[in] step The step of scroll distance(pixel). */ void SetWheelScrollDistanceStep(float step); @@ -261,7 +240,6 @@ public: /** * @brief Get the step of scroll distance in actor coordinates for each wheel event received. * - * @since_tizen 2.4 * @return The step of scroll distance(pixel) */ float GetWheelScrollDistanceStep() const; @@ -273,7 +251,6 @@ public: * The anchor position is the position where all the items in the layout * are aligned to their closest rounded layout positions in integer. * - * @since_tizen 2.4 * @param[in] enabled Whether the anchor animation is enabled or not. */ void SetAnchoring(bool enabled); @@ -281,7 +258,6 @@ public: /** * @brief Get whether the anchor animation is enabled or not. * - * @since_tizen 2.4 * @return Whether the anchor animation is enabled or not. */ bool GetAnchoring() const; @@ -292,16 +268,14 @@ public: * This is the time taken to reach the nearest anchor position after * a drag or swipe gesture ends. * - * @since_tizen 2.4 - * @param[in] durationSeconds The duration of the anchor animation in seconds. * @pre durationSeconds must be greater than zero. + * @param[in] durationSeconds The duration of the anchor animation in seconds. */ void SetAnchoringDuration(float durationSeconds); /** * @brief Get the duration of the anchor animation in seconds. * - * @since_tizen 2.4 * @return The duration of the anchor animation */ float GetAnchoringDuration() const; @@ -309,22 +283,18 @@ public: /** * @brief Scroll the current layout to a particular item. * - * @since_tizen 2.4 - * @param[in] itemId The ID of an item in the layout. - * @param[in] durationSeconds How long the scrolling takes in seconds. * @pre durationSeconds must be zero or greater; zero means the layout should scroll to the particular item instantly. * If calling this with zero second of duration immediately after calling ActivateLayout, it might not work unless * the duration of relayout animation for ActivateLayout is also set to be zero. + * @param[in] itemId The ID of an item in the layout. + * @param[in] durationSeconds How long the scrolling takes in seconds. */ void ScrollToItem(ItemId itemId, float durationSeconds); /** - * @brief Set the interval between refreshes. - * - * When the layout-position of items is changed by this interval, + * @brief Set the interval between refreshes. When the layout-position of items is changed by this interval, * new items are requested from ItemFactory. * - * @since_tizen 2.4 * @param[in] intervalLayoutPositions The refresh interval in layout position. */ void SetRefreshInterval(float intervalLayoutPositions); @@ -332,21 +302,18 @@ public: /** * @brief Get the interval between refreshes in layout position. * - * @since_tizen 2.4 * @return The refresh interval */ float GetRefreshInterval() const; /** * @brief Do a refresh of the item view. - * @since_tizen 2.4 */ void Refresh(); /** * @brief Given the Item ID, this returns the accompanying actor. * - * @since_tizen 2.4 * @param[in] itemId The Item ID of the actor required. * @return The Actor corresponding to the Item ID. */ @@ -355,7 +322,6 @@ public: /** * @brief Returns the Item ID of the specified actor. * - * @since_tizen 2.4 * @param[in] actor The actor whose Item ID is required. * @return The Item ID of the item. * @pre The actor should be an item of ItemView. @@ -372,20 +338,18 @@ public: * ID 2 - ActorB ID 2 - ActorZ ! * ID 3 - ActorC ID 3 - ActorB * ID 4 - ActorC - * @since_tizen 2.4 + * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. * @param[in] newItem The item to insert. * @param[in] durationSeconds How long the relayout takes in seconds. - * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. */ void InsertItem(Item newItem, float durationSeconds); /** * @brief Insert a set of items; this is more efficient than calling InsertItem() repeatedly. * - * @since_tizen 2.4 + * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. * @param[in] newItems The items to insert. * @param[in] durationSeconds How long the relayout takes in seconds. - * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. */ void InsertItems(const ItemContainer& newItems, float durationSeconds); @@ -399,20 +363,18 @@ public: * ID 2 - ActorB ID 2 - ActorC (previously ID 3) * ID 3 - ActorC ID 3 - ActorB (previously ID 4) * ID 4 - ActorD - * @since_tizen 2.4 + * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. * @param[in] itemId The Item ID of the item to remove. * @param[in] durationSeconds How long the relayout takes in seconds. - * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. */ void RemoveItem(ItemId itemId, float durationSeconds); /** * @brief Remove a set of items; this is more efficient than calling RemoveItem() repeatedly. * - * @since_tizen 2.4 + * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. * @param[in] itemIds The IDs of the items to remove. * @param[in] durationSeconds How long the relayout takes in seconds. - * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. */ void RemoveItems(const ItemIdContainer& itemIds, float durationSeconds); @@ -420,10 +382,9 @@ public: * @brief Replace an item. * * A relayout will occur for the replacement item only. - * @since_tizen 2.4 + * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. * @param[in] replacementItem The replacement for an existing item. * @param[in] durationSeconds How long the relayout takes in seconds. - * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. */ void ReplaceItem(Item replacementItem, float durationSeconds); @@ -431,10 +392,9 @@ public: * @brief Replace a set of items. * * A relayout will occur for the replacement items only. - * @since_tizen 2.4 + * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. * @param[in] replacementItems The replacements for a set of existing items. * @param[in] durationSeconds How long the relayout takes in seconds. - * @pre durationSeconds must be zero or greater; zero means the relayout occurs instantly. */ void ReplaceItems(const ItemContainer& replacementItems, float durationSeconds); @@ -442,7 +402,6 @@ public: * @brief Set the parent origin of the items * * A relayout will occur for all the items if the parent origin is different than the current one. - * @since_tizen 2.4 * @param[in] parentOrigin New parent origin position vector */ void SetItemsParentOrigin( const Vector3& parentOrigin ); @@ -450,7 +409,6 @@ public: /** * @brief Get the parent origin of the items * - * @since_tizen 2.4 * @return The current parent origin of the items */ Vector3 GetItemsParentOrigin() const; @@ -459,7 +417,6 @@ public: * @brief Set the anchor point of the items * * A relayout will occur for all the items if the anchor point is different than the current one. - * @since_tizen 2.4 * @param[in] anchorPoint New anchor point position vector */ void SetItemsAnchorPoint( const Vector3& anchorPoint ); @@ -467,7 +424,6 @@ public: /** * @brief Get the anchor point of the items * - * @since_tizen 2.4 * @return The current anchor point of the items */ Vector3 GetItemsAnchorPoint() const; @@ -475,7 +431,6 @@ public: /** * @brief Get the range of items that are currently in ItemView. * - * @since_tizen 2.4 * @param[out] range The range of items. */ void GetItemsRange(ItemRange& range); @@ -489,9 +444,8 @@ public: // Signals * @code * void YourCallbackName(); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ ItemView::LayoutActivatedSignalType& LayoutActivatedSignal(); @@ -500,7 +454,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL ItemView(Internal::ItemView& implementation); @@ -508,7 +461,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL ItemView( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-constraints.h b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-constraints.h index 4b1d037..15a29d6 100644 --- a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-constraints.h +++ b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-constraints.h @@ -32,7 +32,7 @@ class PropertyInput; namespace Toolkit { /** - * @addtogroup dali_toolkit_controls_scroll_view + * @addtogroup dali-toolkit-controls-scroll-view * @{ */ @@ -43,18 +43,16 @@ namespace Toolkit */ /** - * @brief Move Actor constraint. + * Move Actor constraint. * * Moves an Actor in accordance to scroll position. - * @since_tizen 2.4 */ DALI_IMPORT_API void MoveActorConstraint( Vector3& current, const PropertyInputContainer& inputs ); /** - * @brief Wrap Actor constraint. + * Wrap Actor constraint. * * Wraps an Actors position in accordance to min/max bounds of domain. - * @since_tizen 2.4 */ DALI_IMPORT_API void WrapActorConstraint( Vector3& position, const PropertyInputContainer& inputs ); diff --git a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-effect.h b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-effect.h index 831b7af..4af0442 100644 --- a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-effect.h +++ b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-effect.h @@ -38,7 +38,7 @@ class ScrollViewEffect; class ScrollViewWobbleEffect; } /** - * @addtogroup dali_toolkit_controls_scroll_view + * @addtogroup dali-toolkit-controls-scroll-view * @{ */ @@ -53,7 +53,6 @@ class ScrollViewEffect; * properties that can be used with visual effects. Such as creating * constraints that are applied to ShaderEffects or Actors using these * properties as inputs. - * @since_tizen 2.4 */ class DALI_IMPORT_API ScrollViewEffect : public Dali::BaseHandle { @@ -64,7 +63,6 @@ public: * @brief Create an uninitialized ScrollViewEffect; this can only be initialized with derived classes. * * Calling member functions with an uninitialized Toolkit::BaseObject is not allowed. - * @since_tizen 2.4 */ ScrollViewEffect(); @@ -73,7 +71,6 @@ public: // Not intended for application developers /** * @brief This constructor is used by Dali New() methods. * - * @since_tizen 2.4 * @param [in] impl A pointer to a newly allocated Dali resource */ explicit DALI_INTERNAL ScrollViewEffect(Internal::ScrollViewEffect *impl); diff --git a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-page-path-effect.h b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-page-path-effect.h index 8199a8f..af59f83 100644 --- a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-page-path-effect.h +++ b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-page-path-effect.h @@ -35,19 +35,19 @@ namespace Internal DALI_INTERNAL class ScrollViewPagePathEffect; } /** - * @addtogroup dali_toolkit_controls_scroll_view + * @addtogroup dali-toolkit-controls-scroll-view * @{ */ /** - * @brief ScrollView Page Path Effect. - * + * ScrollView Page Path Effect. * This effect causes Actors to follow a given path. The opacity of the actor will be 0.0 at * the beginning of the path and will go to 1.0 as it is approximating to half of the path to return * to 0.0 at the end of the path * * * ScrollView + * | * Page (1..n) * * You should ensure ScrollView's default constraints have been removed, @@ -59,7 +59,6 @@ class ScrollViewPagePathEffect; * * Automatic operation: * not implemented. - * @since_tizen 2.4 */ class DALI_IMPORT_API ScrollViewPagePathEffect : public ScrollViewEffect { @@ -67,8 +66,7 @@ class DALI_IMPORT_API ScrollViewPagePathEffect : public ScrollViewEffect public: /** - * @brief Create an initialized ScrollViewPagePathEffect. - * @since_tizen 2.4 + * Create an initialized ScrollViewPagePathEffect. * @param[in] path The path that will be used by the scroll effect * @param[in] forward Vector in page object space which will be aligned with the tangent of the path * @param[in] inputPropertyIndex Index of a property of the scroll-view which will be used as the input for the path. @@ -79,26 +77,21 @@ public: static ScrollViewPagePathEffect New(Path path, const Vector3& forward, Dali::Property::Index inputPropertyIndex, const Vector3& pageSize, unsigned int pageCount); /** - * @brief Create an uninitialized ScrollViewPagePathEffect; this can be initialized with ScrollViewPagePathEffect::New() + * Create an uninitialized ScrollViewPagePathEffect; this can be initialized with ScrollViewPagePathEffect::New() * Calling member functions with an uninitialized Toolkit::ScrollViewPagePathEffect is not allowed. - * @since_tizen 2.4 */ ScrollViewPagePathEffect(); /** - * @brief Downcast a handle to ScrollViewPagePathEffect handle. - * - * If handle points to a ScrollViewPagePathEffect the + * Downcast an Object handle to ScrollViewPagePathEffect. If handle points to a ScrollViewPagePathEffect the * downcast produces valid handle. If not the returned handle is left uninitialized. - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a ScrollViewPagePathEffect or an uninitialized handle */ static ScrollViewPagePathEffect DownCast( BaseHandle handle ); /** - * @brief Manually apply effect to a page in the scroll-view. - * @since_tizen 2.4 + * Manually apply effect to a page in the scroll-view. * @param[in] page The page to be affected by this effect. * @param[in] pageOrder The order of the page in the scroll-view */ @@ -107,8 +100,7 @@ public: protected: /** - * @brief This constructor is used by Dali New() methods. - * @since_tizen 2.4 + * This constructor is used by Dali New() methods. * @param [in] impl A pointer to a newly allocated Dali resource */ explicit DALI_INTERNAL ScrollViewPagePathEffect( Internal::ScrollViewPagePathEffect *impl ); diff --git a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view.h b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view.h index fde83ee..508b3d2 100644 --- a/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view.h +++ b/dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view.h @@ -35,24 +35,22 @@ namespace Internal DALI_INTERNAL class ScrollView; } /** - * @addtogroup dali_toolkit_controls_scroll_view + * @addtogroup dali-toolkit-controls-scroll-view * @{ */ /** * @brief How axes/rotation or scale are clamped - * @since_tizen 2.4 */ enum ClampState { - NotClamped, ///< The quantity isn't clamped @since_tizen 2.4 - ClampedToMin, ///< The quantity is clamped to the min value @since_tizen 2.4 - ClampedToMax ///< The quantity is clamped to the max value @since_tizen 2.4 + NotClamped, ///< The quantity isn't clamped + ClampedToMin, ///< The quantity is clamped to the min value + ClampedToMax ///< The quantity is clamped to the max value }; /** * @brief A 2 dimensional clamp - * @since_tizen 2.4 */ struct ClampState2D { @@ -62,28 +60,25 @@ struct ClampState2D /** * @brief The snap type - * @since_tizen 2.4 */ enum SnapType { - Snap, ///< Snap @since_tizen 2.4 - Flick ///< Flick @since_tizen 2.4 + Snap, ///< Snap + Flick ///< Flick }; /** * @brief DirectionBias types. - * @since_tizen 2.4 */ enum DirectionBias { - DirectionBiasLeft = -1, ///< Bias scroll snap to Left @since_tizen 2.4 - DirectionBiasNone = 0, ///< Don't bias scroll snap @since_tizen 2.4 - DirectionBiasRight = 1 ///< Bias scroll snap to Right @since_tizen 2.4 + DirectionBiasLeft = -1, ///< Bias scroll snap to Left + DirectionBiasNone = 0, ///< Don't bias scroll snap + DirectionBiasRight = 1 ///< Bias scroll snap to Right }; /** * @brief Used for specifying minimum/maximum extents of a ruler. - * @since_tizen 2.4 */ class DALI_IMPORT_API RulerDomain { @@ -92,7 +87,6 @@ public: /** * @brief Creates Ruler domain allowing a point to traverse between min and max extents. * - * @since_tizen 2.4 * @param[in] min Minimum extent (point cannot traverse less than this) * @param[in] max Maximum extent (point cannot traverse greater than this) * @param[in] enabled Whether domain has been enabled or not. @@ -111,7 +105,6 @@ public: * An optional length parameter can be specified to suggest that the * subject is not a point but a line to that should be clamped. * - * @since_tizen 2.4 * @param[in] x X point to be clamped between (min) and (max) extents. * @param[in] length (optional) The Length of the line from (x) to (x + length) to be clamped. * @param[in] scale Scaling parameter which treats domain as scaled in calculations. @@ -125,7 +118,6 @@ public: * An optional length parameter can be specified to suggest that the * subject is not a point but a line to that should be clamped. * - * @since_tizen 2.4 * @param[in] x X point to be clamped between (min) and (max) extents. * @param[in] length (optional) The Length of the line from (x) to (x + length) to be clamped. * @param[in] scale Scaling parameter which treats domain as scaled in calculations. @@ -137,7 +129,6 @@ public: /** * @brief Returns (max-min) size of ruler. * - * @since_tizen 2.4 * @return The size of the ruler from min to max. */ float GetSize() const; @@ -152,30 +143,26 @@ class RulerExtension; * * It can specify whether they are traversable, where their snap * points are and their domain. - * @since_tizen 2.4 */ class DALI_IMPORT_API Ruler : public RefObject { public: /// @brief The type of the ruler - /// @since_tizen 2.4 enum RulerType { - Fixed, ///< A fixed ruler @since_tizen 2.4 - Free ///< A free ruler @since_tizen 2.4 + Fixed, ///< A fixed ruler + Free ///< A free ruler }; public: /** * @brief Constructs ruler, default enabled, with limitless domain. - * @since_tizen 2.4 */ Ruler(); /** * @brief Snaps (x) in accordance to the ruler settings. * - * @since_tizen 2.4 * @param[in] x The input value on the ruler to be snapped. * @param[in] bias (optional) The biasing employed for snapping * 0 floor input (floor x) "Used for Flick Left" @@ -194,7 +181,6 @@ public: * number of pages within the domain), while wrapping the position * within the domain. * - * @since_tizen 2.4 * @param[in] page The page index * @param[out] volume The overflow volume when the page exceeds the domain (wrap must be enabled) * @param[in] wrap Enable wrap mode @@ -208,7 +194,6 @@ public: * * If (wrap) is true, then will return a page wrapped within the domain. * - * @since_tizen 2.4 * @param[in] position The position on the domain * @param[in] wrap Enable wrap mode * @return The page where this position resides. @@ -218,7 +203,6 @@ public: /** * @brief Returns the total number of pages within this Ruler. * - * @since_tizen 2.4 * @return The number of pages in the Ruler. */ virtual unsigned int GetTotalPages() const = 0; @@ -226,7 +210,6 @@ public: /** * @brief Gets the extension interface of the Ruler. * - * @since_tizen 2.4 * @return The extension interface of the Ruler */ virtual RulerExtension* GetExtension() { return NULL; } @@ -236,7 +219,6 @@ public: /** * @brief Gets the ruler type. * - * @since_tizen 2.4 * @return The ruler type. */ Ruler::RulerType GetType() const; @@ -244,27 +226,23 @@ public: /** * @brief Returns whether this axis has been enabled or not. * - * @since_tizen 2.4 * @return true if axis is enabled */ bool IsEnabled() const; /** * @brief Enables ruler (ruler must be enabled in order to traverse along it). - * @since_tizen 2.4 */ void Enable(); /** * @brief Disables ruler. - * @since_tizen 2.4 */ void Disable(); /** * @brief Sets Domain. * - * @since_tizen 2.4 * @param[in] domain Ruler domain object. */ void SetDomain(RulerDomain domain); @@ -272,14 +250,12 @@ public: /** * @brief Gets Domain. * - * @since_tizen 2.4 * @return The domain */ const RulerDomain &GetDomain() const; /** * @brief Disables Domain (minimum/maximum extents for this axis). - * @since_tizen 2.4 */ void DisableDomain(); @@ -289,7 +265,6 @@ public: * An optional length parameter can be specified to suggest that the * subject is not a point but a line that should be clamped. * - * @since_tizen 2.4 * @param[in] x X point to be clamped between (min) and (max) extents. * @param[in] length (optional) The Length of the line from (x) to (x + length) to be clamped. * @param[in] scale Scaling parameter which treats domain as scaled in calculations. @@ -304,7 +279,6 @@ public: * An optional length parameter can be specified to suggest that the * subject is not a point but a line to that should be clamped. * - * @since_tizen 2.4 * @param[in] x X point to be clamped between (min) and (max) extents. * @param[in] length (optional) The Length of the line from (x) to (x + length) to be clamped. * @param[in] scale Scaling parameter which treats domain as scaled in calculations. @@ -316,7 +290,6 @@ public: /** * @brief Snaps and Clamps (x) in accordance to ruler settings. * - * @since_tizen 2.4 * @param[in] x value to be snapped in accordance to ruler snap value, * and clamped in accordance to the ruler's domain (if set). * @param[in] bias (optional) The biasing employed for snapping @@ -333,7 +306,6 @@ public: /** * @brief Snaps and Clamps (x) in accordance to ruler settings. * - * @since_tizen 2.4 * @param[in] x value to be snapped in accordance to ruler snap value, * and clamped in accordance to the ruler's domain (if set). * @param[in] bias (optional) The biasing employed for snapping @@ -352,7 +324,6 @@ protected: /** * @brief Destructor - A reference counted object may only be deleted by calling Unreference(). - * @since_tizen 2.4 */ virtual ~Ruler(); @@ -364,18 +335,16 @@ protected: }; -typedef IntrusivePtr RulerPtr; ///< Pointer to Ruler object @since_tizen 2.4 +typedef IntrusivePtr RulerPtr; ///< Pointer to Dali::Toolkit::Ruler object /** * @brief Concrete implementation of Ruler that has no snapping and has one single page. - * @since_tizen 2.4 */ class DALI_IMPORT_API DefaultRuler : public Ruler { public: /** * @brief DefaultRuler constructor. - * @since_tizen 2.4 */ DefaultRuler(); @@ -402,7 +371,6 @@ public: /** * @brief Concrete implementation of Ruler that has fixed snapping. - * @since_tizen 2.4 */ class DALI_IMPORT_API FixedRuler : public Ruler { @@ -410,7 +378,6 @@ public: /** * @brief Constructor * - * @since_tizen 2.4 * @param[in] spacing The spacing between each interval on this ruler. */ FixedRuler(float spacing = 1.0f); @@ -446,7 +413,10 @@ class ScrollView; * @brief ScrollView contains actors that can be scrolled manually (via touch) * or automatically. * - * @since_tizen 2.4 + * Signals + * | %Signal Name | Method | + * |-------------------|----------------------------| + * | snap-started | @ref SnapStartedSignal() | */ class DALI_IMPORT_API ScrollView : public Scrollable { @@ -455,7 +425,6 @@ public: /** * @brief Clamp signal event's data - * @since_tizen 2.4 */ struct ClampEvent { @@ -466,7 +435,6 @@ public: /** * @brief Snap signal event's data. - * @since_tizen 2.4 */ struct SnapEvent { @@ -477,55 +445,52 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { ANIMATABLE_PROPERTY_START_INDEX = Toolkit::Scrollable::ANIMATABLE_PROPERTY_END_INDEX + 1, - ANIMATABLE_PROPERTY_END_INDEX = ANIMATABLE_PROPERTY_START_INDEX + 1000 ///< Reserve animatable property indices @since_tizen 2.4 + ANIMATABLE_PROPERTY_END_INDEX = ANIMATABLE_PROPERTY_START_INDEX + 1000 ///< Reserve animatable property indices }; /** * @brief An enumeration of properties belonging to the ScrollView class. - * @since_tizen 2.4 */ struct Property { enum { - SCROLL_POSITION = ANIMATABLE_PROPERTY_START_INDEX, ///< Property, name "scroll-position", type Vector2 @since_tizen 2.4 - SCROLL_PRE_POSITION, ///< Property, name "scroll-pre-position", type Vector2 @since_tizen 2.4 - SCROLL_PRE_POSITION_X, ///< Property, name "scroll-pre-position-x", type float @since_tizen 2.4 - SCROLL_PRE_POSITION_Y, ///< Property, name "scroll-pre-position-y", type float @since_tizen 2.4 - SCROLL_PRE_POSITION_MAX, ///< Property, name "scroll-pre-position-max", type Vector2 @since_tizen 2.4 - SCROLL_PRE_POSITION_MAX_X, ///< Property, name "scroll-pre-position-max-x", type float @since_tizen 2.4 - SCROLL_PRE_POSITION_MAX_Y, ///< Property, name "scroll-pre-position-max-y", type float @since_tizen 2.4 - OVERSHOOT_X, ///< Property, name "overshoot-x", type float @since_tizen 2.4 - OVERSHOOT_Y, ///< Property, name "overshoot-y", type float @since_tizen 2.4 - SCROLL_FINAL, ///< Property, name "scroll-final", type Vector2 @since_tizen 2.4 - SCROLL_FINAL_X, ///< Property, name "scroll-final-x", type float @since_tizen 2.4 - SCROLL_FINAL_Y, ///< Property, name "scroll-final-y", type float @since_tizen 2.4 - WRAP, ///< Property, name "wrap", type bool @since_tizen 2.4 - PANNING, ///< Property, name "panning", type bool @since_tizen 2.4 - SCROLLING, ///< Property, name "scrolling", type bool @since_tizen 2.4 - SCROLL_DOMAIN_SIZE, ///< Property, name "scroll-domain-size" type Vector2 @since_tizen 2.4 - SCROLL_DOMAIN_SIZE_X, ///< Property, name "scroll-domain-size-x" type float @since_tizen 2.4 - SCROLL_DOMAIN_SIZE_Y, ///< Property, name "scroll-domain-size-y" type float @since_tizen 2.4 - SCROLL_DOMAIN_OFFSET, ///< Property, name "scroll-domain-offset" type Vector2 @since_tizen 2.4 - SCROLL_POSITION_DELTA, ///< Property, name "scroll-position-delta" type Vector2 @since_tizen 2.4 - START_PAGE_POSITION ///< Property, name "start-page-position" type Vector3 @since_tizen 2.4 + SCROLL_POSITION = ANIMATABLE_PROPERTY_START_INDEX, ///< Property, name "scroll-position", type Vector2 + SCROLL_PRE_POSITION, ///< Property, name "scroll-pre-position", type Vector2 + SCROLL_PRE_POSITION_X, ///< Property, name "scroll-pre-position-x", type float + SCROLL_PRE_POSITION_Y, ///< Property, name "scroll-pre-position-y", type float + SCROLL_PRE_POSITION_MAX, ///< Property, name "scroll-pre-position-max", type Vector2 + SCROLL_PRE_POSITION_MAX_X, ///< Property, name "scroll-pre-position-max-x", type float + SCROLL_PRE_POSITION_MAX_Y, ///< Property, name "scroll-pre-position-max-y", type float + OVERSHOOT_X, ///< Property, name "overshoot-x", type float + OVERSHOOT_Y, ///< Property, name "overshoot-y", type float + SCROLL_FINAL, ///< Property, name "scroll-final", type Vector2 + SCROLL_FINAL_X, ///< Property, name "scroll-final-x", type float + SCROLL_FINAL_Y, ///< Property, name "scroll-final-y", type float + WRAP, ///< Property, name "wrap", type bool + PANNING, ///< Property, name "panning", type bool + SCROLLING, ///< Property, name "scrolling", type bool + SCROLL_DOMAIN_SIZE, ///< Property, name "scroll-domain-size" type Vector2 + SCROLL_DOMAIN_SIZE_X, ///< Property, name "scroll-domain-size-x" type float + SCROLL_DOMAIN_SIZE_Y, ///< Property, name "scroll-domain-size-y" type float + SCROLL_DOMAIN_OFFSET, ///< Property, name "scroll-domain-offset" type Vector2 + SCROLL_POSITION_DELTA, ///< Property, name "scroll-position-delta" type Vector2 + START_PAGE_POSITION ///< Property, name "start-page-position" type Vector3 }; }; // Typedefs - typedef Signal< void ( const SnapEvent& ) > SnapStartedSignalType; ///< SnapStarted signal type @since_tizen 2.4 + typedef Signal< void ( const SnapEvent& ) > SnapStartedSignalType; ///< SnapStarted signal type public: /** * @brief Creates an empty ScrollView handle. - * @since_tizen 2.4 */ ScrollView(); @@ -534,7 +499,6 @@ public: * * Creates another handle that points to the same real object * - * @since_tizen 2.4 * @param[in] handle to copy from */ ScrollView( const ScrollView& handle ); @@ -543,7 +507,6 @@ public: * @brief Assignment operator. * * Changes this handle to point to another real object - * @since_tizen 2.4 * @param[in] handle The handle to copy from * @return A reference to this */ @@ -553,25 +516,22 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~ScrollView(); /** * @brief Create an initialized ScrollView. * - * @since_tizen 2.4 * @return A handle to a newly allocated Dali resource. */ static ScrollView New(); /** - * @brief Downcast a handle to ScrollView handle. + * @brief Downcast an Object handle to ScrollView. * * If handle points to a ScrollView the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a ScrollView or an uninitialized handle */ @@ -582,7 +542,6 @@ public: /** * @brief Get snap-animation's AlphaFunction. * - * @since_tizen 2.4 * @return Current easing alpha function of the snap animation. */ AlphaFunction GetScrollSnapAlphaFunction() const; @@ -590,7 +549,6 @@ public: /** * @brief Set snap-animation's AlphaFunction. * - * @since_tizen 2.4 * @param[in] alpha Easing alpha function of the snap animation. */ void SetScrollSnapAlphaFunction(AlphaFunction alpha); @@ -598,7 +556,6 @@ public: /** * @brief Get flick-animation's AlphaFunction. * - * @since_tizen 2.4 * @return Current easing alpha function of the flick animation. */ AlphaFunction GetScrollFlickAlphaFunction() const; @@ -606,7 +563,6 @@ public: /** * @brief Set flick-animation's AlphaFunction. * - * @since_tizen 2.4 * @param[in] alpha Easing alpha function of the flick animation. */ void SetScrollFlickAlphaFunction(AlphaFunction alpha); @@ -616,7 +572,6 @@ public: * * This animation occurs when the user drags, and releases. * - * @since_tizen 2.4 * @return The time in seconds for the animation to take. */ float GetScrollSnapDuration() const; @@ -626,7 +581,6 @@ public: * * This animation occurs when the user drags, and releases. * - * @since_tizen 2.4 * @param[in] time The time in seconds for the animation to take. */ void SetScrollSnapDuration(float time); @@ -636,7 +590,6 @@ public: * * This animation occurs when the user flicks scroll view. * - * @since_tizen 2.4 * @return The time in seconds for the animation to take. */ float GetScrollFlickDuration() const; @@ -646,7 +599,6 @@ public: * * This animation occurs when the user flicks scroll view. * - * @since_tizen 2.4 * @param[in] time The time in seconds for the animation to take. */ void SetScrollFlickDuration(float time); @@ -657,7 +609,6 @@ public: * Defines how scrolling horizontally is snapped, and * the boundary (domain) in which the ScrollView can pan. * - * @since_tizen 2.4 * @param[in] ruler The ruler to be used for the X axis */ void SetRulerX(RulerPtr ruler); @@ -668,7 +619,6 @@ public: * Defines how scrolling vertically is snapped, and the boundary * (domain) in which the ScrollView can pan. * - * @since_tizen 2.4 * @param[in] ruler The ruler to be used for the Y axis */ void SetRulerY(RulerPtr ruler); @@ -676,11 +626,10 @@ public: /** * @brief Set Scroll's touch sensitivity. * - * @since_tizen 2.4 - * @param[in] sensitive true to enable scroll, false to disable scrolling * @note Unlike SetSensitive(), this determines whether this ScrollView * should react (e.g. pan), without disrupting the sensitivity of it's children. * + * @param[in] sensitive true to enable scroll, false to disable scrolling */ void SetScrollSensitive(bool sensitive); @@ -692,7 +641,6 @@ public: * edge of a scrollable area and the maximum overshoot is 100 then * the final overshoot value will be 0.75f) * - * @since_tizen 2.4 * @param[in] overshootX the maximum number of horizontally scrolled pixels before overshoot X reaches 1.0f * @param[in] overshootY the maximum number of vertically scrolled pixels before overshoot Y reaches 1.0f */ @@ -701,7 +649,6 @@ public: /** * @brief Set Snap Overshoot animation's AlphaFunction. * - * @since_tizen 2.4 * @param[in] alpha Easing alpha function of the overshoot snap animation. */ void SetSnapOvershootAlphaFunction(AlphaFunction alpha); @@ -709,10 +656,9 @@ public: /** * @brief Set Snap Overshoot animation's Duration. * - * @since_tizen 2.4 - * @param[in] duration The duration of the overshoot snap animation. * @note Set duration to 0 seconds, to disable Animation. * + * @param[in] duration The duration of the overshoot snap animation. */ void SetSnapOvershootDuration(float duration); @@ -723,7 +669,6 @@ public: * snap to the closest actor (The closest actor will appear in the center of * the ScrollView). * - * @since_tizen 2.4 * @param[in] enable Enables (true), or disables (false) Actor AutoSnap */ void SetActorAutoSnap(bool enable); @@ -733,18 +678,16 @@ public: * * When enabled, the ScrollView contents are wrapped over the X/Y Domain. * - * @since_tizen 2.4 - * @param[in] enable Enables (true), or disables (false) Wrap Mode. * @note You must apply a position constraint that causes Wrapping * to all children. * + * @param[in] enable Enables (true), or disables (false) Wrap Mode. */ void SetWrapMode(bool enable); /** * @brief Gets the current distance needed to scroll for ScrollUpdatedSignal to be emitted * - * @since_tizen 2.4 * @return Current scroll update distance */ int GetScrollUpdateDistance() const; @@ -755,7 +698,6 @@ public: * The scroll update distance tells ScrollView how far to move before ScrollUpdatedSignal the informs application. * Each time the ScrollView crosses this distance the signal will be emitted * - * @since_tizen 2.4 * @param[in] distance The distance for ScrollView to move before emitting update signal */ void SetScrollUpdateDistance(int distance); @@ -763,7 +705,6 @@ public: /** * @brief Returns state of Axis Auto Lock mode. * - * @since_tizen 2.4 * @return Whether Axis Auto Lock mode has been enabled or not. */ bool GetAxisAutoLock() const; @@ -775,7 +716,6 @@ public: * vertical, will be automatically restricted to horizontal only or vertical * only panning, until the pan gesture has completed. * - * @since_tizen 2.4 * @param[in] enable Enables (true), or disables (false) AxisAutoLock mode. */ void SetAxisAutoLock(bool enable); @@ -784,7 +724,6 @@ public: * @brief Gets the gradient threshold at which a panning gesture * should be locked to the Horizontal or Vertical axis. * - * @since_tizen 2.4 * @return The gradient, a value between 0.0 and 1.0f. */ float GetAxisAutoLockGradient() const; @@ -796,11 +735,10 @@ public: * By default this is 0.36 (0.36:1) which means angles less than 20 * degrees to an axis will lock to that axis. * - * @since_tizen 2.4 - * @param[in] gradient A value between 0.0 and 1.0 (auto-lock for all angles) - * @note Specifying a value of 1.0 (the maximum value accepted) indicates that + * @note: Specifying a value of 1.0 (the maximum value accepted) indicates that * all panning gestures will auto-lock. Either to the horizontal or vertical axis. * + * @param[in] gradient A value between 0.0 and 1.0 (auto-lock for all angles) */ void SetAxisAutoLockGradient(float gradient); @@ -810,7 +748,6 @@ public: * * This is a value in stage-diagonals per second^2. * stage-diagonal = Length( stage.width, stage.height ) - * @since_tizen 2.4 * @return Friction coefficient is returned. */ float GetFrictionCoefficient() const; @@ -825,7 +762,6 @@ public: * A stage 480x800 in size has a diagonal length of 933. * Friction coefficient of 1.0 means the swipe velocity will * reduce by 1.0 * 933 pixels/sec^2. - * @since_tizen 2.4 * @param[in] friction Friction coefficient, must be greater than 0.0 (default = 1.0) */ void SetFrictionCoefficient(float friction); @@ -837,7 +773,6 @@ public: * This is a constant which multiplies the input touch * flick velocity to determine the actual velocity at * which to move the scrolling area. - * @since_tizen 2.4 * @return The flick speed coefficient is returned. */ float GetFlickSpeedCoefficient() const; @@ -849,7 +784,6 @@ public: * This is a constant which multiplies the input touch * flick velocity to determine the actual velocity at * which to move the scrolling area. - * @since_tizen 2.4 * @param[in] speed The flick speed coefficient (default = 1.0). */ void SetFlickSpeedCoefficient(float speed); @@ -857,7 +791,6 @@ public: /** * @brief Returns the minimum pan distance required for a flick gesture in pixels * - * @since_tizen 2.4 * @return Minimum pan distance vector with separate x and y distance */ Vector2 GetMinimumDistanceForFlick() const; @@ -867,7 +800,6 @@ public: * * Takes a Vector2 containing separate x and y values. As long as the pan distance exceeds one of these axes a flick will be allowed * - * @since_tizen 2.4 * @param[in] distance The minimum pan distance for a flick */ void SetMinimumDistanceForFlick( const Vector2& distance ); @@ -875,7 +807,6 @@ public: /** * @brief Returns the minimum pan speed required for a flick gesture in pixels per second * - * @since_tizen 2.4 * @return Minimum pan speed */ float GetMinimumSpeedForFlick() const; @@ -883,7 +814,6 @@ public: /** * @brief Sets the minimum pan speed required for a flick in pixels per second * - * @since_tizen 2.4 * @param[in] speed The minimum pan speed for a flick */ void SetMinimumSpeedForFlick( float speed ); @@ -894,7 +824,6 @@ public: * * This is a value in stage-diagonals per second. * stage-diagonal = Length( stage.width, stage.height ) - * @since_tizen 2.4 * @return Maximum flick speed is returned */ float GetMaxFlickSpeed() const; @@ -909,7 +838,6 @@ public: * A stage 480x800 in size has a diagonal length of 933. * Max Flick speed of 1.0 means the maximum velocity of * a swipe can be 1.0 * 933 pixels/sec. - * @since_tizen 2.4 * @param[in] speed Maximum flick speed (default = 3.0) */ void SetMaxFlickSpeed(float speed); @@ -918,7 +846,6 @@ public: * @brief Gets the step of scroll distance in actor coordinates for * each wheel event received in free panning mode. * - * @since_tizen 2.4 * @return The step of scroll distance(pixel) in X and Y axes. */ Vector2 GetWheelScrollDistanceStep() const; @@ -927,10 +854,9 @@ public: * @brief Sets the step of scroll distance in actor coordinates for * each wheel event received in free panning mode. * - * @since_tizen 2.4 * @param[in] step The step of scroll distance(pixel) in X and Y axes. * - * @note If snap points are defined in the rulers, it will always + * @note: If snap points are defined in the rulers, it will always * scroll to the next snap point towards the scroll direction while * receiving the wheel events. * @@ -941,7 +867,6 @@ public: * @brief Retrieves current scroll position. * * @returns The current scroll position. - * @since_tizen 2.4 */ Vector2 GetCurrentScrollPosition() const; @@ -951,8 +876,7 @@ public: * a grid fashion, increasing from left to right until the end of * the X-domain. * - * @since_tizen 2.4 - * @note Pages start from 0 as the first page, not 1. + * @note: Pages start from 0 as the first page, not 1. * * @returns The Current page. */ @@ -965,10 +889,9 @@ public: * increasing Y scrolls contents up. * - If Rulers have been applied to the axes, then the contents will scroll until * reaching the domain boundary. - * @since_tizen 2.4 - * @param[in] position The position to scroll to. * @note Contents will not snap to ruler snap points. * + * @param[in] position The position to scroll to. */ void ScrollTo(const Vector2& position); @@ -979,11 +902,10 @@ public: * increasing Y scrolls contents up. * - If Rulers have been applied to the axes, then the contents will scroll until * reaching the domain boundary. - * @since_tizen 2.4 - * @param[in] position The position to scroll to. - * @param[in] duration The duration of the animation in seconds * @note Contents will not snap to ruler snap points. * + * @param[in] position The position to scroll to. + * @param[in] duration The duration of the animation in seconds */ void ScrollTo(const Vector2& position, float duration); @@ -994,12 +916,11 @@ public: * increasing Y scrolls contents up. * - If Rulers have been applied to the axes, then the contents will scroll until * reaching the domain boundary. - * @since_tizen 2.4 + * @note Contents will not snap to ruler snap points. + * * @param[in] position The position to scroll to. * @param[in] duration The duration of the animation in seconds * @param[in] alpha The alpha function to use - * @note Contents will not snap to ruler snap points. - * */ void ScrollTo(const Vector2& position, float duration, AlphaFunction alpha); @@ -1010,16 +931,15 @@ public: * increasing Y scrolls contents up. * - If Rulers have been applied to the axes, then the contents will scroll until * reaching the domain boundary. - * @since_tizen 2.4 - * @param[in] position The position to scroll to. - * @param[in] duration The duration of the animation in seconds - * @param[in] horizontalBias Whether to bias scrolling to left or right. - * @param[in] verticalBias Whether to bias scrolling to top or bottom. * @note Contents will not snap to ruler snap points. * Biasing parameters are provided such that in scenarios with 2 or 2x2 pages in * wrap mode, the application developer can decide whether to scroll left or right * to get to the target page * + * @param[in] position The position to scroll to. + * @param[in] duration The duration of the animation in seconds + * @param[in] horizontalBias Whether to bias scrolling to left or right. + * @param[in] verticalBias Whether to bias scrolling to top or bottom. */ void ScrollTo(const Vector2& position, float duration, DirectionBias horizontalBias, DirectionBias verticalBias); @@ -1031,17 +951,16 @@ public: * increasing Y scrolls contents up. * - If Rulers have been applied to the axes, then the contents will scroll until * reaching the domain boundary. - * @since_tizen 2.4 - * @param[in] position The position to scroll to. - * @param[in] duration The duration of the animation in seconds - * @param[in] horizontalBias Whether to bias scrolling to left or right. - * @param[in] verticalBias Whether to bias scrolling to top or bottom. - * @param[in] alpha Alpha function to use * @note Contents will not snap to ruler snap points. * Biasing parameters are provided such that in scenarios with 2 or 2x2 pages in * wrap mode, the application developer can decide whether to scroll left or right * to get to the target page * + * @param[in] position The position to scroll to. + * @param[in] duration The duration of the animation in seconds + * @param[in] horizontalBias Whether to bias scrolling to left or right. + * @param[in] verticalBias Whether to bias scrolling to top or bottom. + * @param[in] alpha Alpha function to use */ void ScrollTo(const Vector2& position, float duration, AlphaFunction alpha, DirectionBias horizontalBias, DirectionBias verticalBias); @@ -1050,12 +969,11 @@ public: * @brief Scrolls View to page currently based on assumption that each page is * "(page) * ScrollViewSize.width, 0". * - * @since_tizen 2.4 - * @param[in] page to scroll to * @note Should probably be upgraded so that page is an abstract class, that can be * a function of ScrollViewSize, ruler domain, ruler snap points etc. as pages may be * orchestrated in a 2D grid fashion, or variable width. * + * @param[in] page to scroll to */ void ScrollTo(unsigned int page); @@ -1063,13 +981,12 @@ public: * @brief Scrolls View to page currently based on assumption that each page is * "(page) * ScrollViewSize.width, 0". * - * @since_tizen 2.4 - * @param[in] page to scroll to - * @param[in] duration The duration of the animation in seconds * @note Should probably be upgraded so that page is an abstract class, that can be * a function of ScrollViewSize, ruler domain, ruler snap points etc. as pages may be * orchestrated in a 2D grid fashion, or variable width. * + * @param[in] page to scroll to + * @param[in] duration The duration of the animation in seconds */ void ScrollTo(unsigned int page, float duration); @@ -1077,10 +994,6 @@ public: * @brief Scrolls View to page currently based on assumption that each page is * "(page) * ScrollViewSize.width, 0". * - * @since_tizen 2.4 - * @param[in] page to scroll to - * @param[in] duration The duration of the animation in seconds - * @param[in] bias Whether to bias scrolling to left or right. * @note Should probably be upgraded so that page is an abstract class, that can be * a function of ScrollViewSize, ruler domain, ruler snap points etc. as pages may be * orchestrated in a 2D grid fashion, or variable width. @@ -1088,27 +1001,28 @@ public: * the application developer can decide whether to scroll left or right to get to * the target page. * + * @param[in] page to scroll to + * @param[in] duration The duration of the animation in seconds + * @param[in] bias Whether to bias scrolling to left or right. */ void ScrollTo(unsigned int page, float duration, DirectionBias bias); /** * @brief Scrolls View such that actor appears in the center of the ScrollView. * - * @since_tizen 2.4 - * @param[in] actor The actor to center in on (via Scrolling). * @note Actor must be a direct child of ScrollView, otherwise will * cause an assertion failure. + * @param[in] actor The actor to center in on (via Scrolling). */ void ScrollTo(Actor& actor); /** * @brief Scrolls View such that actor appears in the center of the ScrollView. * - * @since_tizen 2.4 - * @param[in] actor The actor to center in on (via Scrolling). - * @param[in] duration The duration of the animation in seconds * @note Actor must be a direct child of ScrollView, otherwise will * cause an assertion failure. + * @param[in] actor The actor to center in on (via Scrolling). + * @param[in] duration The duration of the animation in seconds */ void ScrollTo(Actor& actor, float duration); @@ -1117,7 +1031,6 @@ public: * * If already at snap points, then will return false, and not scroll. * - * @since_tizen 2.4 * @return True if Snapping necessary. */ bool ScrollToSnapPoint(); @@ -1125,16 +1038,14 @@ public: /** * @brief Applies a constraint that will affect the children of ScrollView. * - * @since_tizen 2.4 - * @param[in] constraint The constraint to apply * @note this affects all existing and future Actors that are added to scrollview. + * @param[in] constraint The constraint to apply */ void ApplyConstraintToChildren(Constraint constraint); /** * @brief Removes all constraints that will affect the children of ScrollView. * - * @since_tizen 2.4 * @note this removes all constraints from actors that have been added * to scrollview. */ @@ -1143,7 +1054,6 @@ public: /** * @brief Apply Effect to ScrollView. * - * @since_tizen 2.4 * @param[in] effect The effect to apply to scroll view */ void ApplyEffect(ScrollViewEffect effect); @@ -1151,14 +1061,12 @@ public: /** * @brief Remove Effect from ScrollView. * - * @since_tizen 2.4 * @param[in] effect The effect to remove. */ void RemoveEffect(ScrollViewEffect effect); /** * @brief Remove All Effects from ScrollView. - * @since_tizen 2.4 */ void RemoveAllEffects(); @@ -1168,7 +1076,6 @@ public: * Once an actor is bound to a ScrollView, it will be subject to * that ScrollView's properties. * - * @since_tizen 2.4 * @param[in] child The actor to add to this ScrollView. */ void BindActor(Actor child); @@ -1177,17 +1084,15 @@ public: * @brief Unbind Actor from this ScrollView. * * Once Unbound, this ScrollView will not affect the actor. - * @since_tizen 2.4 - * @param[in] child The actor to be unbound. * @note this does not remove the child from the ScrollView container * + * @param[in] child The actor to be unbound. */ void UnbindActor(Actor child); /** * @brief Allows the user to constrain the scroll view in a particular direction. * - * @since_tizen 2.4 * @param[in] direction The axis to constrain the scroll-view to. * Usually set to PanGestureDetector::DIRECTION_VERTICAL or PanGestureDetector::DIRECTION_HORIZONTAL (but can be any other angle if desired). * @param[in] threshold The threshold to apply around the axis. @@ -1198,7 +1103,6 @@ public: /** * @brief Remove a direction constraint from the scroll view. * - * @since_tizen 2.4 * @param[in] direction The axis to stop constraining to. * Usually will be PanGestureDetector::DIRECTION_VERTICAL or PanGestureDetector::DIRECTION_HORIZONTAL (but can be any other angle if desired). */ @@ -1214,9 +1118,8 @@ public: // Signals * @code * void YourCallbackName(const SnapEvent& event); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ SnapStartedSignalType& SnapStartedSignal(); @@ -1225,7 +1128,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL ScrollView(Internal::ScrollView& implementation); @@ -1233,7 +1135,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL ScrollView( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/scrollable/scrollable.h b/dali-toolkit/public-api/controls/scrollable/scrollable.h index 5eb1d4c..d43a29a 100644 --- a/dali-toolkit/public-api/controls/scrollable/scrollable.h +++ b/dali-toolkit/public-api/controls/scrollable/scrollable.h @@ -32,7 +32,7 @@ namespace Internal DALI_INTERNAL class Scrollable; } /** - * @addtogroup dali_toolkit_controls_scrollable + * @addtogroup dali-toolkit-controls-scrollable * @{ */ @@ -42,7 +42,12 @@ class Scrollable; * * Scrollables such as ScrollView and ItemView can be derived from this class. * - * @since_tizen 2.4 + * Signals + * | %Signal Name | Method | + * |-------------------|------------------------------| + * | scroll-started | @ref ScrollStartedSignal() | + * | scroll-completed | @ref ScrollUpdatedSignal() | + * | scroll-updated | @ref ScrollCompletedSignal() | */ class DALI_IMPORT_API Scrollable : public Control { @@ -50,53 +55,50 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000, ///< Reserve property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000, ///< Reserve property indices ANIMATABLE_PROPERTY_START_INDEX = ANIMATABLE_PROPERTY_REGISTRATION_START_INDEX, - ANIMATABLE_PROPERTY_END_INDEX = ANIMATABLE_PROPERTY_REGISTRATION_START_INDEX + 1000 ///< Reserve animatable property indices @since_tizen 2.4 + ANIMATABLE_PROPERTY_END_INDEX = ANIMATABLE_PROPERTY_REGISTRATION_START_INDEX + 1000 ///< Reserve animatable property indices }; /** * @brief An enumeration of properties belonging to the Scrollable class. - * @since_tizen 2.4 */ struct Property { enum { // Event side properties - OVERSHOOT_EFFECT_COLOR = PROPERTY_START_INDEX, ///< Property, name "overshoot-effect-color", @see SetOvershootEffectColor(), type Vector4 @since_tizen 2.4 - OVERSHOOT_ANIMATION_SPEED, ///< Property, name "overshoot-animation-speed", @see SetOvershootAnimationSpeed(), type float @since_tizen 2.4 + OVERSHOOT_EFFECT_COLOR = PROPERTY_START_INDEX, ///< Property, name "overshoot-effect-color", @see SetOvershootEffectColor(), type Vector4 + OVERSHOOT_ANIMATION_SPEED, ///< Property, name "overshoot-animation-speed", @see SetOvershootAnimationSpeed(), type float // Animatable properties - SCROLL_RELATIVE_POSITION = ANIMATABLE_PROPERTY_START_INDEX, ///< Property, name "scroll-relative-position", type Vector2 @since_tizen 2.4 - SCROLL_POSITION_MIN, ///< Property, name "scroll-position-min", type Vector2 @since_tizen 2.4 - SCROLL_POSITION_MIN_X, ///< Property, name "scroll-position-min-x", type float @since_tizen 2.4 - SCROLL_POSITION_MIN_Y, ///< Property, name "scroll-position-min-y", type float @since_tizen 2.4 - SCROLL_POSITION_MAX, ///< Property, name "scroll-position-max", type Vector2 @since_tizen 2.4 - SCROLL_POSITION_MAX_X, ///< Property, name "scroll-position-max-x", type float @since_tizen 2.4 - SCROLL_POSITION_MAX_Y, ///< Property, name "scroll-position-max-y", type float @since_tizen 2.4 - CAN_SCROLL_VERTICAL, ///< Property, name "can-scroll-vertical", type bool @since_tizen 2.4 - CAN_SCROLL_HORIZONTAL ///< Property, name "can-scroll-horizontal", type bool @since_tizen 2.4 + SCROLL_RELATIVE_POSITION = ANIMATABLE_PROPERTY_START_INDEX, ///< Property, name "scroll-relative-position", type Vector2 + SCROLL_POSITION_MIN, ///< Property, name "scroll-position-min", type Vector2 + SCROLL_POSITION_MIN_X, ///< Property, name "scroll-position-min-x", type float + SCROLL_POSITION_MIN_Y, ///< Property, name "scroll-position-min-y", type float + SCROLL_POSITION_MAX, ///< Property, name "scroll-position-max", type Vector2 + SCROLL_POSITION_MAX_X, ///< Property, name "scroll-position-max-x", type float + SCROLL_POSITION_MAX_Y, ///< Property, name "scroll-position-max-y", type float + CAN_SCROLL_VERTICAL, ///< Property, name "can-scroll-vertical", type bool + CAN_SCROLL_HORIZONTAL ///< Property, name "can-scroll-horizontal", type bool }; }; // Typedefs - typedef Signal< void ( const Vector2& ) > ScrollStartedSignalType; ///< ScrollStarted signal type @since_tizen 2.4 - typedef Signal< void ( const Vector2& ) > ScrollCompletedSignalType; ///< ScrollCompleted signal type @since_tizen 2.4 - typedef Signal< void ( const Vector2& ) > ScrollUpdatedSignalType; ///< Scroll updated signal type @since_tizen 2.4 + typedef Signal< void ( const Vector2& ) > ScrollStartedSignalType; ///< ScrollStarted signal type + typedef Signal< void ( const Vector2& ) > ScrollCompletedSignalType; ///< ScrollCompleted signal type + typedef Signal< void ( const Vector2& ) > ScrollUpdatedSignalType; ///< Scroll updated signal type public: /** * @brief Creates an uninitialized Scrollable handle. - * @since_tizen 2.4 */ Scrollable(); @@ -105,7 +107,6 @@ public: * * Creates another handle that points to the same real object * - * @since_tizen 2.4 * @param handle to copy from */ Scrollable( const Scrollable& handle ); @@ -114,7 +115,6 @@ public: * @brief Assignment operator. * * Changes this handle to point to another real object - * @since_tizen 2.4 * @param[in] handle to copy from * @return A reference to this */ @@ -124,17 +124,15 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~Scrollable(); /** - * @brief Downcast a handle to Scrollable handle. + * @brief Downcast an Object handle to Scrollable. * * If handle points to a Scrollable the downcast produces valid * handle. If not the returned handle is left uninitialized. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a Scrollable or an uninitialized handle */ @@ -143,7 +141,6 @@ public: /** * @brief Checks if scroll overshoot has been enabled or not. * - * @since_tizen 2.4 * @return Whether the scroll obvershoot is enabled */ bool IsOvershootEnabled() const; @@ -151,7 +148,6 @@ public: /** * @brief Sets whether to enables or disable scroll overshoot. * - * @since_tizen 2.4 * @param[in] enable Whether to enable the scroll obvershoot or not */ void SetOvershootEnabled(bool enable); @@ -159,30 +155,25 @@ public: /** * @brief Set the color of the overshoot effect. * - * @since_tizen 2.4 * @param[in] color The color of the overshoot effect. */ void SetOvershootEffectColor( const Vector4& color ); /** * @brief Get the color of the overshoot effect. - * @since_tizen 2.4 * @return The color of the overshoot effect. */ Vector4 GetOvershootEffectColor() const; /** * @brief Set the speed of overshoot animation in pixels per second. - * * When the speed is not greater than 0, the overshoot is set instantly with no animation. - * @since_tizen 2.4 * @param[in] pixelsPerSecond The speed of the overshoot animation. */ void SetOvershootAnimationSpeed( float pixelsPerSecond ); /** * @brief Get the speed of overshoot animation in pixels per second. - * @since_tizen 2.4 * @return The speed of the overshoot animation. */ float GetOvershootAnimationSpeed() const; @@ -196,9 +187,8 @@ public: // Signals * @code * void YourCallbackName(const Vector2& currentScrollPosition); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ ScrollStartedSignalType& ScrollStartedSignal(); @@ -209,9 +199,8 @@ public: // Signals * @code * void YourCallbackName(const Vector2& currentScrollPosition); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ ScrollUpdatedSignalType& ScrollUpdatedSignal(); @@ -222,9 +211,8 @@ public: // Signals * @code * void YourCallbackName(const Vector2& currentScrollPosition); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ ScrollCompletedSignalType& ScrollCompletedSignal(); @@ -233,7 +221,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL Scrollable(Internal::Scrollable& implementation); @@ -241,7 +228,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL Scrollable( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/table-view/table-view.h b/dali-toolkit/public-api/controls/table-view/table-view.h index 0829117..7f51cb0 100644 --- a/dali-toolkit/public-api/controls/table-view/table-view.h +++ b/dali-toolkit/public-api/controls/table-view/table-view.h @@ -36,7 +36,7 @@ namespace Internal DALI_INTERNAL class TableView; } /** - * @addtogroup dali_toolkit_controls_table_view + * @addtogroup dali-toolkit-controls-table-view * @{ */ @@ -55,7 +55,13 @@ class TableView; * * These properties are registered dynamically to the child and is non-animatable. * - * @since_tizen 2.4 + * | %Property Name | Type | + * |---------------------------|-------------| + * | cell-index | Vector2 | + * | row-span | float | + * | column-span | float | + * | cell-horizontal-alignment | string | + * | cell-vertical-alignment | string | */ class DALI_IMPORT_API TableView : public Control { @@ -63,12 +69,11 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices }; /** @@ -78,58 +83,54 @@ public: * It has the format as follows in script: * @code * "layout-rows": - * { - * "0": { "policy": "fixed", "value": 40 }, //@see SetFixedHight - * "2": { "policy": "relative", "value": 0.33 }, //@see SetRelativeHeight - * "3": { "policy": "fit", "value":0.0 } //@see SetFitHeight, the value is not used, its height is decided by the children in this row - * } + { + "0": { "policy": "fixed", "value": 40 }, //@see SetFixedHight + "2": { "policy": "relative", "value": 0.33 }, //@see SetRelativeHeight + "3": { "policy": "fit", "value":0.0 } //@see SetFitHeight, the value is not used, its height is decided by the children in this row + } * @endcode * * LayoutColumns: set the height of the rows. * It has the format as follows in script: * @code * "layout-columns": - * { - * "0": { "policy": "fixed", "value": 40 }, //@see SetFixedWidth - * "1": { "policy": "fit", "value":0.0 } //@see SetFitHeight, the value is not used, its width is decided by the children in this column - * "2": { "policy": "relative", "value": 0.33 } //@see SetRelativeWidth - * } + { + "0": { "policy": "fixed", "value": 40 }, //@see SetFixedWidth + "1": { "policy": "fit", "value":0.0 } //@see SetFitHeight, the value is not used, its width is decided by the children in this column + "2": { "policy": "relative", "value": 0.33 } //@see SetRelativeWidth + } * @endcode - * @since_tizen 2.4 */ struct Property { enum { - ROWS = PROPERTY_START_INDEX, ///< type unsigned int @since_tizen 2.4 - COLUMNS, ///< type unsigned int @since_tizen 2.4 - CELL_PADDING, ///< type Vector2 @since_tizen 2.4 - LAYOUT_ROWS, ///< type Map @since_tizen 2.4 - LAYOUT_COLUMNS, ///< type Map @since_tizen 2.4 + ROWS = PROPERTY_START_INDEX, ///< name "rows", type unsigned int + COLUMNS, ///< name "columns", type unsigned int + CELL_PADDING, ///< name "cell-padding", type Vector2 + LAYOUT_ROWS, ///< name "layout-rows", type Map + LAYOUT_COLUMNS, ///< name "layout-columns", type Map }; }; /** * @brief Describes how the size of a row / column been set - * @since_tizen 2.4 */ enum LayoutPolicy { - FIXED, ///< Fixed with the given value. @since_tizen 2.4 - RELATIVE, ///< Calculated as percentage of the remainder after subtracting Padding and Fixed height/width @since_tizen 2.4 - FILL, ///< Default policy, get the remainder of the 100% (after subtracting Fixed, Fit and Relative height/ width) divided evenly between 'fill' rows/columns @since_tizen 2.4 - FIT ///< Fit around its children. @since_tizen 2.4 + FIXED, ///< Fixed with the given value. + RELATIVE, ///< Calculated as percentage of the remainder after subtracting Padding and Fixed height/width + FILL, ///< Default policy, get the remainder of the 100% (after subtracting Fixed, Fit and Relative height/ width) divided evenly between 'fill' rows/columns + FIT ///< Fit around its children. }; /** - * @brief Structure to specify layout position for child actor - * @since_tizen 2.4 + * Structure to specify layout position for child actor */ struct CellPosition { /** - * @brief Constructor to initialise values to defaults for convenience - * @since_tizen 2.4 + * Constructor to initialise values to defaults for convenience */ CellPosition( unsigned int rowIndex = 0, unsigned int columnIndex = 0, unsigned int rowSpan = 1, unsigned int columnSpan = 1 ) @@ -144,22 +145,19 @@ public: }; /** - * @brief Create a TableView handle; this can be initialised with TableView::New() + * Create a TableView handle; this can be initialised with TableView::New() * Calling member functions with an uninitialised handle is not allowed. - * @since_tizen 2.4 */ TableView(); /** - * @brief Copy constructor. Creates another handle that points to the same real object - * @since_tizen 2.4 + * Copy constructor. Creates another handle that points to the same real object * @param handle to copy from */ TableView( const TableView& handle ); /** - * @brief Assignment operator. Changes this handle to point to another real object - * @since_tizen 2.4 + * Assignment operator. Changes this handle to point to another real object */ TableView& operator=( const TableView& handle ); @@ -167,13 +165,11 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~TableView(); /** - * @brief Create the TableView control. - * @since_tizen 2.4 + * Create the TableView control. * @param[in] initialRows for the table * @param[in] initialColumns for the table * @return A handle to the TableView control. @@ -181,49 +177,42 @@ public: static TableView New( unsigned int initialRows, unsigned int initialColumns ); /** - * @brief Downcast a handle to TableView handle. - * - * If handle points to a TableView the + * Downcast an Object handle to TableView. If handle points to a TableView the * downcast produces valid handle. If not the returned handle is left uninitialized. - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a TableView or an uninitialized handle */ static TableView DownCast( BaseHandle handle ); /** - * @brief Adds a child to the table + * Adds a child to the table * If the row or column index is outside the table, the table gets resized bigger - * @since_tizen 2.4 + * @pre The child actor has been initialized. * @param[in] child to add * @param[in] position for the child * @return true if the addition succeeded, false if the cell is already occupied - * @pre The child actor has been initialized. */ bool AddChild( Actor child, CellPosition position ); /** - * @brief Returns a child from the given layout position - * @since_tizen 2.4 + * Returns a child from the given layout position + * Note! if there is no child in this position this method returns an uninitialized + * Actor handle * @param[in] position in the table * @return child that was in the cell or an uninitialized handle - * @note if there is no child in this position this method returns an uninitialized - * Actor handle */ Actor GetChildAt( CellPosition position ); /** - * @brief Removes a child from the given layout position - * @since_tizen 2.4 + * Removes a child from the given layout position + * Note! if there is no child in this position this method does nothing * @param[in] position for the child to remove * @return child that was removed or an uninitialized handle - * @note if there is no child in this position this method does nothing */ Actor RemoveChildAt( CellPosition position ); /** - * @brief Finds the childs layout position - * @since_tizen 2.4 + * Finds the childs layout position * @param[in] child to search for * @param[out] position for the child * @return true if the child was included in this TableView @@ -231,87 +220,72 @@ public: bool FindChildPosition( Actor child, CellPosition& position ); /** - * @brief Insert a new row to given index - * @since_tizen 2.4 + * Insert a new row to given index * @param [in] rowIndex of the new row */ void InsertRow( unsigned int rowIndex ); /** - * @brief Delete a row from given index + * Delete a row from given index * Removed elements are deleted - * @since_tizen 2.4 * @param [in] rowIndex of the row to delete */ void DeleteRow( unsigned int rowIndex ); /** - * @brief Delete a row from given index - * @since_tizen 2.4 + * Delete a row from given index * @param [in] rowIndex of the row to delete * @param [out] removed elements */ void DeleteRow( unsigned int rowIndex, std::vector& removed ); /** - * @brief Insert a new column to given index - * @since_tizen 2.4 + * Insert a new column to given index * @param [in] columnIndex of the new column */ void InsertColumn( unsigned int columnIndex ); /** - * @brief Delete a column from given index. + * Delete a column from given index. * Removed elements are deleted - * @since_tizen 2.4 * @param [in] columnIndex of the column to delete */ void DeleteColumn( unsigned int columnIndex ); /** - * @brief Delete a column from given index - * @since_tizen 2.4 + * Delete a column from given index * @param [in] columnIndex of the column to delete * @param [out] removed elements */ void DeleteColumn( unsigned int columnIndex, std::vector& removed ); /** - * @brief Resize the TableView. - * - * @since_tizen 2.4 - * @param[in] rows for the table - * @param[in] columns for the table - * @note if the new size is smaller than old, + * Resize the TableView. Note! if the new size is smaller than old, * superfluous actors get removed. If you want to relayout removed children, * use the variant that returns the removed Actors and reinsert them into the table * If an actor spans to a removed row or column it gets removed from the table + * @param[in] rows for the table + * @param[in] columns for the table */ void Resize( unsigned int rows, unsigned int columns ); /** - * @brief Resize the TableView. - * - * @since_tizen 2.4 + * Resize the TableView. Note! if the new size is smaller than old, + * superfluous actors get removed. + * If an actor spans to a removed row or column it gets removed from the table * @param[in] rows for the table * @param[in] columns for the table * @param[out] removed actor handles - * @note if the new size is smaller than old, - * superfluous actors get removed. - * If an actor spans to a removed row or column it gets removed from the table */ void Resize( unsigned int rows, unsigned int columns, std::vector& removed ); /** - * @brief Set horizontal and vertical padding between cells - * @since_tizen 2.4 + * Set horizontal and vertical padding between cells * @param[in] padding width and height */ void SetCellPadding( Size padding ); /** - * @brief Get the current padding as width and height. - * @since_tizen 2.4 * @return the current padding as width and height */ Size GetCellPadding(); @@ -319,7 +293,6 @@ public: /** * @brief Specify this row as fitting its height to its children * - * @since_tizen 2.4 * @param[in] rowIndex The row to set */ void SetFitHeight( unsigned int rowIndex ); @@ -327,7 +300,6 @@ public: /** * @brief Is the row a fit row * - * @since_tizen 2.4 * @param[in] rowIndex The row to check * @return Return true if the row is fit */ @@ -336,7 +308,6 @@ public: /** * @brief Specify this column as fitting its width to its children * - * @since_tizen 2.4 * @param[in] columnIndex The column to set */ void SetFitWidth( unsigned int columnIndex ); @@ -344,100 +315,87 @@ public: /** * @brief Is the column a fit column * - * @since_tizen 2.4 * @param[in] columnIndex The column to check * @return Return true if the column is fit */ bool IsFitWidth( unsigned int columnIndex ) const; /** - * @brief Sets a row to have fixed height + * Sets a row to have fixed height * Setting a fixed height of 0 has no effect - * @since_tizen 2.4 + * @pre The row rowIndex must exist. * @param rowIndex for row with fixed height * @param height in world coordinate units - * @pre The row rowIndex must exist. */ void SetFixedHeight( unsigned int rowIndex, float height ); /** - * @brief Gets a row's fixed height. - * @since_tizen 2.4 - * @return height in world coordinate units. + * Gets a row's fixed height. + * Note! The returned value is valid if it has been set before. * @pre The row rowIndex must exist. - * @note The returned value is valid if it has been set before. + * @return height in world coordinate units. */ float GetFixedHeight( unsigned int rowIndex ) const; /** - * @brief Sets a row to have relative height. Relative height means percentage of + * Sets a row to have relative height. Relative height means percentage of * the remainder of the table height after subtracting Padding and Fixed height rows * Setting a relative height of 0 has no effect - * @since_tizen 2.4 + * @pre The row rowIndex must exist. * @param rowIndex for row with relative height * @param heightPercentage between 0.0f and 1.0f - * @pre The row rowIndex must exist. */ void SetRelativeHeight( unsigned int rowIndex, float heightPercentage ); /** - * @brief Gets a row's relative height. - * @since_tizen 2.4 - * @return height in percentage units, between 0.0f and 1.0f. + * Gets a row's relative height. + * Note! The returned value is valid if it has been set before. * @pre The row rowIndex must exist. - * @note The returned value is valid if it has been set before. + * @return height in percentage units, between 0.0f and 1.0f. */ float GetRelativeHeight( unsigned int rowIndex ) const; /** - * @brief Sets a column to have fixed width + * Sets a column to have fixed width * Setting a fixed width of 0 has no effect - * @since_tizen 2.4 + * @pre The column columnIndex must exist. * @param columnIndex for column with fixed width * @param width in world coordinate units - * @pre The column columnIndex must exist. */ void SetFixedWidth( unsigned int columnIndex, float width ); /** - * @brief Gets a column's fixed width. - * @since_tizen 2.4 - * @return width in world coordinate units. + * Gets a column's fixed width. + * Note! The returned value is valid if it has been set before. * @pre The column columnIndex must exist. - * @note The returned value is valid if it has been set before. + * @return width in world coordinate units. */ float GetFixedWidth( unsigned int columnIndex ) const; /** - * @brief Sets a column to have relative width. Relative width means percentage of + * Sets a column to have relative width. Relative width means percentage of * the remainder of table width after subtracting Padding and Fixed width columns * Setting a relative width of 0 has no effect - * @since_tizen 2.4 + * @pre The column columnIndex must exist. * @param columnIndex for column with fixed width * @param widthPercentage between 0.0f and 1.0f - * @pre The column columnIndex must exist. */ void SetRelativeWidth( unsigned int columnIndex, float widthPercentage ); /** - * @brief Gets a column's relative width. - * @since_tizen 2.4 - * @return width in percentage units, between 0.0f and 1.0f. + * Gets a column's relative width. + * Note! The returned value is valid if it has been set before. * @pre The column columnIndex must exist. - * @note The returned value is valid if it has been set before. + * @return width in percentage units, between 0.0f and 1.0f. */ float GetRelativeWidth( unsigned int columnIndex ) const; /** - * @brief Gets the amount of rows in the table. - * @since_tizen 2.4 * @return the amount of rows in the table */ unsigned int GetRows(); /** - * @brief Gets the amount of columns in the table. - * @since_tizen 2.4 * @return the amount of columns in the table */ unsigned int GetColumns(); @@ -447,7 +405,6 @@ public: * * Cells without calling this function have the default values of LEFT and TOP respectively. * - * @since_tizen 2.4 * @param[in] position The cell to set alignment on. * @param[in] horizontal The horizontal alignment. * @param[in] vertical The vertical alignment. @@ -457,15 +414,13 @@ public: public: // Not intended for application developers /** - * @brief Creates a handle using the Toolkit::Internal implementation. - * @since_tizen 2.4 + * Creates a handle using the Toolkit::Internal implementation. * @param[in] implementation The Control implementation. */ DALI_INTERNAL TableView(Internal::TableView& implementation); /** - * @brief Allows the creation of this Control from an Internal::CustomActor pointer. - * @since_tizen 2.4 + * Allows the creation of this Control from an Internal::CustomActor pointer. * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL TableView( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/text-controls/text-field.h b/dali-toolkit/public-api/controls/text-controls/text-field.h index c7e9c16..7b9d11b 100644 --- a/dali-toolkit/public-api/controls/text-controls/text-field.h +++ b/dali-toolkit/public-api/controls/text-controls/text-field.h @@ -32,14 +32,19 @@ namespace Internal DALI_INTERNAL class TextField; } /** - * @addtogroup dali_toolkit_controls_text_controls + * @addtogroup dali-toolkit-controls-text-controls * @{ */ /** * @brief A control which provides a single-line editable text field. * - * @since_tizen 2.4 + * * Signals + * | %Signal Name | Method | + * |------------------------|-----------------------------------------------------| + * | text-changed | @ref TextChangedSignal() | + * | max-length-reached | @ref MaxLengthReachedSignal() | + * */ class DALI_IMPORT_API TextField : public Control { @@ -47,56 +52,54 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices }; /** * @brief An enumeration of properties belonging to the TextLabel class. - * @since_tizen 2.4 */ struct Property { enum { - RENDERING_BACKEND = PROPERTY_START_INDEX, ///< The type of rendering, type INT @since_tizen 2.4 @see RenderingType - TEXT, ///< The text to display in UTF-8 format, type STRING @since_tizen 2.4 - PLACEHOLDER_TEXT, ///< The text to display when the TextField is empty and inactive, type STRING @since_tizen 2.4 - PLACEHOLDER_TEXT_FOCUSED, ///< The text to display when the TextField is empty with key-input focus, type STRING @since_tizen 2.4 - FONT_FAMILY, ///< The requested font family, type STRING @since_tizen 2.4 - FONT_STYLE, ///< The requested font style, type STRING @since_tizen 2.4 - POINT_SIZE, ///< The size of font in points, type FLOAT @since_tizen 2.4 - MAX_LENGTH, ///< The maximum number of characters that can be inserted, type INTEGER @since_tizen 2.4 - EXCEED_POLICY, ///< Specifies how the text is truncated when it does not fit, type INTEGER @since_tizen 2.4 - HORIZONTAL_ALIGNMENT, ///< The line horizontal alignment, type STRING, values "BEGIN", "CENTER", "END" @since_tizen 2.4 - VERTICAL_ALIGNMENT, ///< The line vertical alignment, type STRING, values "TOP", "CENTER", "BOTTOM" @since_tizen 2.4 - TEXT_COLOR, ///< The text color, type VECTOR4 @since_tizen 2.4 - PLACEHOLDER_TEXT_COLOR, ///< The placeholder-text color, type VECTOR4 @since_tizen 2.4 - SHADOW_OFFSET, ///< The drop shadow offset 0 indicates no shadow, type VECTOR2 @since_tizen 2.4 - SHADOW_COLOR, ///< The color of a drop shadow, type VECTOR4 @since_tizen 2.4 - PRIMARY_CURSOR_COLOR, ///< The color to apply to the primary cursor, type VECTOR4 @since_tizen 2.4 - SECONDARY_CURSOR_COLOR, ///< The color to apply to the secondary cursor, type VECTOR4 @since_tizen 2.4 - ENABLE_CURSOR_BLINK, ///< Whether the cursor should blink or not, type BOOLEAN @since_tizen 2.4 - CURSOR_BLINK_INTERVAL, ///< The time interval in seconds between cursor on/off states, type FLOAT @since_tizen 2.4 - CURSOR_BLINK_DURATION, ///< The cursor will stop blinking after this number of seconds (if non-zero), type FLOAT @since_tizen 2.4 - CURSOR_WIDTH, ///< The cursor width, type INTEGER @since_tizen 2.4 - GRAB_HANDLE_IMAGE, ///< The image to display for the grab handle, type STRING @since_tizen 2.4 - GRAB_HANDLE_PRESSED_IMAGE, ///< The image to display when the grab handle is pressed, type STRING @since_tizen 2.4 - SCROLL_THRESHOLD, ///< Scrolling will occur if the cursor is this close to the control border, type FLOAT @since_tizen 2.4 - SCROLL_SPEED, ///< The scroll speed in pixels per second, type FLOAT @since_tizen 2.4 - SELECTION_HANDLE_IMAGE_LEFT, ///< The image to display for the left selection handle, type MAP @since_tizen 2.4 - SELECTION_HANDLE_IMAGE_RIGHT, ///< The image to display for the right selection handle, type MAP @since_tizen 2.4 - SELECTION_HANDLE_PRESSED_IMAGE_LEFT, ///< The image to display when the left selection handle is pressed, type MAP @since_tizen 2.4 - SELECTION_HANDLE_PRESSED_IMAGE_RIGHT, ///< The image to display when the right selection handle is pressed, type MAP @since_tizen 2.4 - SELECTION_HANDLE_MARKER_IMAGE_LEFT, ///< The image to display for the left selection handle marker, type MAP @since_tizen 2.4 - SELECTION_HANDLE_MARKER_IMAGE_RIGHT, ///< The image to display for the right selection handle marker, type MAP @since_tizen 2.4 - SELECTION_HIGHLIGHT_COLOR, ///< The color of the selection highlight, type VECTOR4 @since_tizen 2.4 - DECORATION_BOUNDING_BOX, ///< The decorations (handles etc) will positioned within this area on-screen, type RECTANGLE @since_tizen 2.4 - INPUT_METHOD_SETTINGS ///< The settings to relating to the System's Input Method, Key and Value type MAP @since_tizen 2.4 + RENDERING_BACKEND = PROPERTY_START_INDEX, ///< name "rendering-backend", The type or rendering e.g. bitmap-based, type INT + TEXT, ///< name "text", The text to display in UTF-8 format, type STRING + PLACEHOLDER_TEXT, ///< name "placeholder-text", The text to display when the TextField is empty and inactive, type STRING + PLACEHOLDER_TEXT_FOCUSED, ///< name "placeholder-text-focused", The text to display when the TextField is empty with key-input focus, type STRING + FONT_FAMILY, ///< name "font-family", The requested font family, type STRING + FONT_STYLE, ///< name "font-style", The requested font style, type STRING + POINT_SIZE, ///< name "point-size", The size of font in points, type FLOAT + MAX_LENGTH, ///< name "max-length" The maximum number of characters that can be inserted, type INTEGER + EXCEED_POLICY, ///< name "exceed-policy" Specifies how the text is truncated when it does not fit, type INTEGER + HORIZONTAL_ALIGNMENT, ///< name "horizontal-alignment", The line horizontal alignment, type STRING, values "BEGIN", "CENTER", "END" + VERTICAL_ALIGNMENT, ///< name "vertical-alignment", The line vertical alignment, type STRING, values "TOP", "CENTER", "BOTTOM" + TEXT_COLOR, ///< name "text-color", The text color, type VECTOR4 + PLACEHOLDER_TEXT_COLOR, ///< name "placeholder-text-color", The placeholder-text color, type VECTOR4 + SHADOW_OFFSET, ///< name "shadow-offset", The drop shadow offset 0 indicates no shadow, type VECTOR2 + SHADOW_COLOR, ///< name "shadow-color", The color of a drop shadow, type VECTOR4 + PRIMARY_CURSOR_COLOR, ///< name "primary-cursor-color", The color to apply to the primary cursor, type VECTOR4 + SECONDARY_CURSOR_COLOR, ///< name "secondary-cursor-color", The color to apply to the secondary cursor, type VECTOR4 + ENABLE_CURSOR_BLINK, ///< name "enable-cursor-blink", Whether the cursor should blink or not, type BOOLEAN + CURSOR_BLINK_INTERVAL, ///< name "cursor-blink-interval", The time interval in seconds between cursor on/off states, type FLOAT + CURSOR_BLINK_DURATION, ///< name "cursor-blink-duration", The cursor will stop blinking after this number of seconds (if non-zero), type FLOAT + CURSOR_WIDTH, ///< name "cursor-width", The cursor width, type INTEGER + GRAB_HANDLE_IMAGE, ///< name "grab-handle-image", The image to display for the grab handle, type STRING + GRAB_HANDLE_PRESSED_IMAGE, ///< name "grab-handle-pressed-image", The image to display when the grab handle is pressed, type STRING + SCROLL_THRESHOLD, ///< name "scroll-threshold" Scrolling will occur if the cursor is this close to the control border, type FLOAT + SCROLL_SPEED, ///< name "scroll-speed" The scroll speed in pixels per second, type FLOAT + SELECTION_HANDLE_IMAGE_LEFT, ///< name "selection-handle-image-left", The image to display for the left selection handle, type MAP + SELECTION_HANDLE_IMAGE_RIGHT, ///< name "selection-handle-image-right", The image to display for the right selection handle, type MAP + SELECTION_HANDLE_PRESSED_IMAGE_LEFT, ///< name "selection-handle-pressed-image-left" The image to display when the left selection handle is pressed, type MAP + SELECTION_HANDLE_PRESSED_IMAGE_RIGHT, ///< name "selection-handle-pressed-image-right" The image to display when the right selection handle is pressed, type MAP + SELECTION_HANDLE_MARKER_IMAGE_LEFT, ///< name "selection-handle-marker-image-left", The image to display for the left selection handle marker, type MAP + SELECTION_HANDLE_MARKER_IMAGE_RIGHT, ///< name "selection-handle-marker-image-right", The image to display for the right selection handle marker, type MAP + SELECTION_HIGHLIGHT_COLOR, ///< name "selection-highlight-color" The color of the selection highlight, type VECTOR4 + DECORATION_BOUNDING_BOX, ///< name "decoration-bounding-box" The decorations (handles etc) will positioned within this area on-screen, type RECTANGLE + INPUT_METHOD_SETTINGS ///< name "input-method-settings" The settings to relating to the System's Input Method, Key and Value type MAP }; }; @@ -104,41 +107,33 @@ public: * @brief Specifies how the text is truncated when it does not fit * * The default value is \e EXCEED_POLICY_CLIP. - * @since_tizen 2.4 */ enum ExceedPolicy { - EXCEED_POLICY_ORIGINAL, ///< The text will be display at original size, and may exceed the TextField boundary. @since_tizen 2.4 - EXCEED_POLICY_CLIP ///< The end of text will be clipped to fit within the TextField. @since_tizen 2.4 + EXCEED_POLICY_ORIGINAL, ///< The text will be display at original size, and may exceed the TextField boundary. + EXCEED_POLICY_CLIP ///< The end of text will be clipped to fit within the TextField. }; // Type Defs - /// @brief Text changed signal type - /// @since_tizen 2.4 + /// @brief Max Characters Exceed signal type; typedef Signal TextChangedSignalType; - - /// @brief Max characters exceed signal type - /// @since_tizen 2.4 typedef Signal MaxLengthReachedSignalType; /** - * @brief Create the TextField control. - * @since_tizen 2.4 + * Create the TextField control. * @return A handle to the TextField control. */ static TextField New(); /** * @brief Creates an empty handle. - * @since_tizen 2.4 */ TextField(); /** * @brief Copy constructor. * - * @since_tizen 2.4 * @param[in] handle The handle to copy from. */ TextField( const TextField& handle ); @@ -146,7 +141,6 @@ public: /** * @brief Assignment operator. * - * @since_tizen 2.4 * @param[in] handle The handle to copy from. * @return A reference to this. */ @@ -156,17 +150,15 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~TextField(); /** - * @brief Downcast a handle to TextField handle. + * @brief Downcast a handle to TextField. * * If the BaseHandle points is a TextField the downcast returns a valid handle. * If not the returned handle is left empty. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a TextField or an empty handle */ @@ -181,7 +173,6 @@ public: * @code * void YourCallbackName( TextField textField ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ TextChangedSignalType& TextChangedSignal(); @@ -193,7 +184,6 @@ public: * @code * void YourCallbackName( TextField textField ); * @endcode - * @since_tizen 2.4 * @return The signal to connect to. */ MaxLengthReachedSignalType& MaxLengthReachedSignal(); @@ -203,7 +193,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL TextField( Internal::TextField& implementation ); @@ -211,7 +200,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL TextField( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/controls/text-controls/text-label.h b/dali-toolkit/public-api/controls/text-controls/text-label.h index 0473f7e..7669b05 100644 --- a/dali-toolkit/public-api/controls/text-controls/text-label.h +++ b/dali-toolkit/public-api/controls/text-controls/text-label.h @@ -32,7 +32,7 @@ namespace Internal DALI_INTERNAL class TextLabel; } /** - * @addtogroup dali_toolkit_controls_text_controls + * @addtogroup dali-toolkit-controls-text-controls * @{ */ @@ -40,7 +40,6 @@ class TextLabel; * @brief A control which renders a short text string. * * Text labels are lightweight, non-editable and do not respond to user input. - * @since_tizen 2.4 */ class DALI_IMPORT_API TextLabel : public Control { @@ -48,43 +47,40 @@ public: /** * @brief The start and end property ranges for this control. - * @since_tizen 2.4 */ enum PropertyRange { PROPERTY_START_INDEX = Control::CONTROL_PROPERTY_END_INDEX + 1, - PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices @since_tizen 2.4 + PROPERTY_END_INDEX = PROPERTY_START_INDEX + 1000 ///< Reserve property indices }; /** * @brief An enumeration of properties belonging to the TextLabel class. - * @since_tizen 2.4 */ struct Property { enum { - RENDERING_BACKEND = PROPERTY_START_INDEX, ///< The type of rendering, type INT @since_tizen 2.4 @see RenderingType - TEXT, ///< The text to display in UTF-8 format, type STRING @since_tizen 2.4 - FONT_FAMILY, ///< The requested font family, type STRING @since_tizen 2.4 - FONT_STYLE, ///< The requested font style, type STRING @since_tizen 2.4 - POINT_SIZE, ///< The size of font in points, type FLOAT @since_tizen 2.4 - MULTI_LINE, ///< The single-line or multi-line layout option, type BOOLEAN @since_tizen 2.4 - HORIZONTAL_ALIGNMENT, ///< The line horizontal alignment, type STRING, values "BEGIN", "CENTER", "END" @since_tizen 2.4 - VERTICAL_ALIGNMENT, ///< The line vertical alignment, type STRING, values "TOP", "CENTER", "BOTTOM" @since_tizen 2.4 - TEXT_COLOR, ///< The text color, type VECTOR4 @since_tizen 2.4 - SHADOW_OFFSET, ///< The drop shadow offset 0 indicates no shadow, type VECTOR2 @since_tizen 2.4 - SHADOW_COLOR, ///< The color of a drop shadow, type VECTOR4 @since_tizen 2.4 - UNDERLINE_ENABLED, ///< The underline enabled flag, type BOOLEAN @since_tizen 2.4 - UNDERLINE_COLOR, ///< The color of the underline, type VECTOR4 @since_tizen 2.4 - UNDERLINE_HEIGHT ///< Overrides the underline height from font metrics, type FLOAT @since_tizen 2.4 + RENDERING_BACKEND = PROPERTY_START_INDEX, ///< name "rendering-backend", The type or rendering e.g. bitmap-based, type INT + TEXT, ///< name "text", The text to display in UTF-8 format, type STRING + FONT_FAMILY, ///< name "font-family", The requested font family, type STRING + FONT_STYLE, ///< name "font-style", The requested font style, type STRING + POINT_SIZE, ///< name "point-size", The size of font in points, type FLOAT + MULTI_LINE, ///< name "multi-line", The single-line or multi-line layout option, type BOOLEAN + HORIZONTAL_ALIGNMENT, ///< name "horizontal-alignment", The line horizontal alignment, type STRING, values "BEGIN", "CENTER", "END" + VERTICAL_ALIGNMENT, ///< name "vertical-alignment", The line vertical alignment, type STRING, values "TOP", "CENTER", "BOTTOM" + TEXT_COLOR, ///< name "text-color", The text color, type VECTOR4 + SHADOW_OFFSET, ///< name "shadow-offset", The drop shadow offset 0 indicates no shadow, type VECTOR2 + SHADOW_COLOR, ///< name "shadow-color", The color of a drop shadow, type VECTOR4 + UNDERLINE_ENABLED, ///< name "underline-enabled", The underline enabled flag, type BOOLEAN + UNDERLINE_COLOR, ///< name "underline-color", The color of the underline, type VECTOR4 + UNDERLINE_HEIGHT ///< name "underline-height", Overrides the underline height from font metrics, type FLOAT }; }; /** * @brief Create the TextLabel control. * - * @since_tizen 2.4 * @return A handle to the TextLabel control. */ static TextLabel New(); @@ -92,7 +88,6 @@ public: /** * @brief Create the TextLabel control. * - * @since_tizen 2.4 * @param[in] text The text to display. * @return A handle to the TextLabel control. */ @@ -100,14 +95,12 @@ public: /** * @brief Creates an empty handle. - * @since_tizen 2.4 */ TextLabel(); /** * @brief Copy constructor. * - * @since_tizen 2.4 * @param[in] handle The handle to copy from. */ TextLabel( const TextLabel& handle ); @@ -115,7 +108,6 @@ public: /** * @brief Assignment operator. * - * @since_tizen 2.4 * @param[in] handle The handle to copy from. * @return A reference to this. */ @@ -125,17 +117,15 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~TextLabel(); /** - * @brief Downcast a handle to TextLabel handle. + * @brief Downcast a handle to TextLabel. * * If the BaseHandle points is a TextLabel the downcast returns a valid handle. * If not the returned handle is left empty. * - * @since_tizen 2.4 * @param[in] handle Handle to an object * @return handle to a TextLabel or an empty handle */ @@ -146,7 +136,6 @@ public: // Not intended for application developers /** * @brief Creates a handle using the Toolkit::Internal implementation. * - * @since_tizen 2.4 * @param[in] implementation The Control implementation. */ DALI_INTERNAL TextLabel( Internal::TextLabel& implementation ); @@ -154,7 +143,6 @@ public: // Not intended for application developers /** * @brief Allows the creation of this Control from an Internal::CustomActor pointer. * - * @since_tizen 2.4 * @param[in] internal A pointer to the internal CustomActor. */ explicit DALI_INTERNAL TextLabel( Dali::Internal::CustomActor* internal ); diff --git a/dali-toolkit/public-api/enums.h b/dali-toolkit/public-api/enums.h index 89b0c48..ff678a9 100644 --- a/dali-toolkit/public-api/enums.h +++ b/dali-toolkit/public-api/enums.h @@ -25,32 +25,29 @@ namespace Dali { /** * @brief DALi Toolkit namespace. - * @since_tizen 2.4 */ namespace Toolkit { /** - * @addtogroup dali_toolkit_controls + * @addtogroup dali-toolkit-controls * @{ */ /** * @brief Control Orientation namespace. - * @since_tizen 2.4 */ namespace ControlOrientation { /** * @brief The internal orientation of a control. - * @since_tizen 2.4 */ enum Type { - Up, ///< The contents of control are in a vertical layout, from top to bottom @since_tizen 2.4 - Left, ///< The contents of control are in a horizontal layout, from left to right @since_tizen 2.4 - Down, ///< The contents of control are in a vertical layout, from bottom to top @since_tizen 2.4 - Right ///< The contents of control are in a horizontal layout, from right to left @since_tizen 2.4 + Up, ///< The contents of control are in a vertical layout, from top to bottom + Left, ///< The contents of control are in a horizontal layout, from left to right + Down, ///< The contents of control are in a vertical layout, from bottom to top + Right ///< The contents of control are in a horizontal layout, from right to left }; } // namespace ControlOrientation @@ -58,7 +55,6 @@ enum Type /** * @brief Query whether an orientation is vertical. * - * @since_tizen 2.4 * @param[in] orientation The orientation. * @return True if the orientation is vertical. */ @@ -67,7 +63,6 @@ DALI_IMPORT_API bool IsVertical(ControlOrientation::Type orientation); /** * @brief Query whether an orientation is horizontal. * - * @since_tizen 2.4 * @param[in] orientation The orientation. * @return True if the orientation is horizontal. */ diff --git a/dali-toolkit/public-api/file.list b/dali-toolkit/public-api/file.list index 5e096b9..1b1194c 100755 --- a/dali-toolkit/public-api/file.list +++ b/dali-toolkit/public-api/file.list @@ -10,6 +10,7 @@ public_api_src_files = \ $(public_api_src_dir)/controls/buttons/radio-button.cpp \ $(public_api_src_dir)/controls/default-controls/solid-color-actor.cpp \ $(public_api_src_dir)/controls/image-view/image-view.cpp \ + $(public_api_src_dir)/controls/model3d-view/model3d-view.cpp \ $(public_api_src_dir)/controls/scroll-bar/scroll-bar.cpp \ $(public_api_src_dir)/controls/scrollable/item-view/default-item-layout.cpp \ $(public_api_src_dir)/controls/scrollable/item-view/item-layout.cpp \ @@ -50,6 +51,9 @@ public_api_buttons_header_files = \ public_api_default_controls_header_files = \ $(public_api_src_dir)/controls/default-controls/solid-color-actor.h +public_api_model3d_view_header_files = \ + $(public_api_src_dir)/controls/model3d-view/model3d-view.h + public_api_gaussian_blur_view_header_files = \ $(public_api_src_dir)/controls/gaussian-blur-view/gaussian-blur-view.h diff --git a/dali-toolkit/public-api/focus-manager/keyboard-focus-manager.h b/dali-toolkit/public-api/focus-manager/keyboard-focus-manager.h index c065a99..3b6b33f 100644 --- a/dali-toolkit/public-api/focus-manager/keyboard-focus-manager.h +++ b/dali-toolkit/public-api/focus-manager/keyboard-focus-manager.h @@ -32,7 +32,7 @@ namespace Internal DALI_INTERNAL class KeyboardFocusManager; } /** - * @addtogroup dali_toolkit_managers + * @addtogroup dali-toolkit-focus-manager * @{ */ @@ -45,7 +45,13 @@ class KeyboardFocusManager; * highlight for the focused actor and emits a signal when the focus * is changed. * - * @since_tizen 2.4 + * Signals + * | %Signal Name | Method | + * |----------------------------------|------------------------------------| + * | keyboard-pre-focus-change | @ref PreFocusChangeSignal() | + * | keyboard-focus-changed | @ref FocusChangedSignal() | + * | keyboard-focus-group-changed | @ref FocusGroupChangedSignal() | + * | keyboard-focused-actor-enter-key | @ref FocusedActorEnterKeySignal() | */ class DALI_IMPORT_API KeyboardFocusManager : public BaseHandle { @@ -53,26 +59,21 @@ class DALI_IMPORT_API KeyboardFocusManager : public BaseHandle public: /// @brief Pre focus change signal - /// @since_tizen 2.4 typedef Signal< Actor ( Actor, Actor, Control::KeyboardFocus::Direction ) > PreFocusChangeSignalType; /// @brief Focus changed signal - /// @since_tizen 2.4 typedef Signal< void ( Actor, Actor ) > FocusChangedSignalType; /// @brief Focus group changed signal - /// @since_tizen 2.4 typedef Signal< void ( Actor, bool ) > FocusGroupChangedSignalType; /// @brief Focused actor has the enter key pressed signal - /// @since_tizen 2.4 typedef Signal< void ( Actor ) > FocusedActorEnterKeySignalType; /** * @brief Create a KeyboardFocusManager handle; this can be initialised with KeyboardFocusManager::New(). * * Calling member functions with an uninitialised handle is not allowed. - * @since_tizen 2.4 */ KeyboardFocusManager(); @@ -80,14 +81,12 @@ public: * @brief Destructor * * This is non-virtual since derived Handle types must not contain data or virtual methods. - * @since_tizen 2.4 */ ~KeyboardFocusManager(); /** * @brief Get the singleton of KeyboardFocusManager object. * - * @since_tizen 2.4 * @return A handle to the KeyboardFocusManager control. */ static KeyboardFocusManager Get(); @@ -98,20 +97,18 @@ public: * Only one actor can be focused at the same time. The actor must * be in the stage already and keyboard focusable. * - * @since_tizen 2.4 - * @param actor The actor to be focused - * @return Whether the focus is successful or not * @pre The KeyboardFocusManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor to be focused + * @return Whether the focus is successful or not */ bool SetCurrentFocusActor(Actor actor); /** * @brief Get the current focused actor. * - * @since_tizen 2.4 - * @return A handle to the current focused actor or an empty handle if no actor is focused. * @pre The KeyboardFocusManager has been initialized. + * @return A handle to the current focused actor or an empty handle if no actor is focused. */ Actor GetCurrentFocusActor(); @@ -120,10 +117,9 @@ public: * chain in the given direction (according to the focus traversal * order). * - * @since_tizen 2.4 + * @pre The KeyboardFocusManager has been initialized. * @param direction The direction of focus movement * @return true if the movement was successful - * @pre The KeyboardFocusManager has been initialized. */ bool MoveFocus(Control::KeyboardFocus::Direction direction); @@ -132,7 +128,6 @@ public: * that no actor is focused in the focus chain. * * It will emit focus changed signal without current focused actor - * @since_tizen 2.4 * @pre The KeyboardFocusManager has been initialized. */ void ClearFocus(); @@ -141,18 +136,16 @@ public: * @brief Set whether the focus movement should be looped within the same focus group. * * The focus movement is not looped by default. - * @since_tizen 2.4 - * @param enabled Whether the focus movement should be looped * @pre The KeyboardFocusManager has been initialized. + * @param enabled Whether the focus movement should be looped */ void SetFocusGroupLoop(bool enabled); /** * @brief Get whether the focus movement should be looped within the same focus group. * - * @since_tizen 2.4 - * @return Whether the focus movement should be looped * @pre The KeyboardFocusManager has been initialized. + * @return Whether the focus movement should be looped */ bool GetFocusGroupLoop() const; @@ -162,29 +155,26 @@ public: * * Layout controls set themselves as focus groups by default. * - * @since_tizen 2.4 - * @param actor The actor to be set as a focus group. - * @param isFocusGroup Whether to set the actor as a focus group or not. * @pre The KeyboardFocusManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor to be set as a focus group. + * @param isFocusGroup Whether to set the actor as a focus group or not. */ void SetAsFocusGroup(Actor actor, bool isFocusGroup); /** * @brief Check whether the actor is set as a focus group or not. * - * @since_tizen 2.4 - * @param actor The actor to be checked. - * @return Whether the actor is set as a focus group. * @pre The KeyboardFocusManager has been initialized. * @pre The Actor has been initialized. + * @param actor The actor to be checked. + * @return Whether the actor is set as a focus group. */ bool IsFocusGroup(Actor actor) const; /** * @brief Returns the closest ancestor of the given actor that is a focus group. * - * @since_tizen 2.4 * @param actor The actor to be checked for its focus group * @return The focus group the given actor belongs to or an empty handle if the given actor * doesn't belong to any focus group @@ -198,19 +188,17 @@ public: * KeyboardFocusManager and will be added to the focused actor as a * highlight. * - * @since_tizen 2.4 - * @param indicator The indicator actor to be added * @pre The KeyboardFocusManager has been initialized. * @pre The indicator actor has been initialized. + * @param indicator The indicator actor to be added */ void SetFocusIndicatorActor(Actor indicator); /** * @brief Get the focus indicator actor. * - * @since_tizen 2.4 - * @return A handle to the focus indicator actor * @pre The KeyboardFocusManager has been initialized. + * @return A handle to the focus indicator actor */ Actor GetFocusIndicatorActor(); @@ -232,9 +220,8 @@ public: // Signals * @code * Actor YourCallbackName(Actor currentFocusedActor, Actor proposedActorToFocus, Control::KeyboardFocus::Direction direction); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ PreFocusChangeSignalType& PreFocusChangeSignal(); @@ -245,9 +232,8 @@ public: // Signals * @code * void YourCallbackName(Actor originalFocusedActor, Actor currentFocusedActor); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ FocusChangedSignalType& FocusChangedSignal(); @@ -263,9 +249,8 @@ public: // Signals * @code * void YourCallbackName(Actor currentFocusedActor, bool forward); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ FocusGroupChangedSignalType& FocusGroupChangedSignal(); @@ -276,9 +261,8 @@ public: // Signals * @code * void YourCallbackName(Actor enterPressedActor); * @endcode - * @since_tizen 2.4 - * @return The signal to connect to. * @pre The Object has been initialized. + * @return The signal to connect to. */ FocusedActorEnterKeySignalType& FocusedActorEnterKeySignal(); @@ -287,7 +271,6 @@ public: // Signals /** * @brief Creates a new handle from the implementation. * - * @since_tizen 2.4 * @param[in] impl A pointer to the object. */ explicit DALI_INTERNAL KeyboardFocusManager(Internal::KeyboardFocusManager *impl); diff --git a/dali-toolkit/public-api/text/rendering-backend.h b/dali-toolkit/public-api/text/rendering-backend.h index 0634c18..83dc054 100644 --- a/dali-toolkit/public-api/text/rendering-backend.h +++ b/dali-toolkit/public-api/text/rendering-backend.h @@ -23,33 +23,18 @@ namespace Dali namespace Toolkit { -/** - * @addtogroup dali_toolkit_controls_text_controls - * @{ - */ -/** - * @brief Text rendering enumerations - * @since_tizen 2.4 - */ namespace Text { - -/** - * @brief The type of text renderer required. - * @since_tizen 2.4 - */ +// The type of text renderer required enum RenderingType { - RENDERING_SHARED_ATLAS ///< A bitmap-based solution where renderers can share a texture atlas @since_tizen 2.4 + RENDERING_SHARED_ATLAS ///< A bitmap-based solution where renderers can share a texture atlas }; const unsigned int DEFAULT_RENDERING_BACKEND = RENDERING_SHARED_ATLAS; } // namespace Text -/** - * @} - */ } // namespace Toolkit } // namespace Dali diff --git a/dali-toolkit/styles/480x800/dali-toolkit-default-theme.json b/dali-toolkit/styles/480x800/dali-toolkit-default-theme.json index c189b63..7229952 100644 --- a/dali-toolkit/styles/480x800/dali-toolkit-default-theme.json +++ b/dali-toolkit/styles/480x800/dali-toolkit-default-theme.json @@ -63,11 +63,13 @@ distributing this software or its derivatives. "point-size":18, "primary-cursor-color":[0.0,0.72,0.9,1.0], "secondary-cursor-color":[0.0,0.72,0.9,1.0], - "cursor-width":2, + "cursor-width":1, "selection-highlight-color":[0.75,0.96,1.0,1.0], - "grab-handle-image" : "{DALI_STYLE_IMAGE_DIR}cursor_handler_drop_center.png", - "selection-handle-image-left" : {"filename":"{DALI_STYLE_IMAGE_DIR}selection_handle_drop_left.png" }, - "selection-handle-image-right": {"filename":"{DALI_STYLE_IMAGE_DIR}selection_handle_drop_right.png" } + "grab-handle-image": { "filename":"{DALI_IMAGE_DIR}cursor_handler_center.png" }, + "selection-handle-image-left" : {"filename":"{DALI_IMAGE_DIR}selection_handle_left.png" }, + "selection-handle-image-right": {"filename":"{DALI_IMAGE_DIR}selection_handle_right.png" }, + "selection-handle-marker-image-left":{ "filename":"{DALI_IMAGE_DIR}selection_marker_left.png" }, + "selection-handle-marker-image-right":{ "filename":"{DALI_IMAGE_DIR}selection_marker_right.png" } }, "textfield-font-size-0": @@ -94,13 +96,11 @@ distributing this software or its derivatives. { "popup-max-size":[400,100], "option-divider-size":[2,0], - "popup-divider-color":[0.24,0.72,0.8,0.3], + "popup-divider-color":[0.23,0.72,0.8,0.11], "popup-icon-color":[1.0,1.0,1.0,1.0], - "popup-pressed-color":[0.24,0.72,0.8,0.3], - "popup-background-image": { - "filename": "{DALI_IMAGE_DIR}core_contextual_popup_bg_stroke_color.9.png", - "background-color":[0.98,0.98,0.98,1.0], - "stroke-color":[0.24,0.72,0.8,1.0] + "popup-pressed-color":[0.24,0.72,0.8,0.11], + "background-image": { + "filename": "{DALI_IMAGE_DIR}selection-popup-bg.9.png" }, "popup-fade-in-duration":0.1, "popup-fade-out-duration":0.1 @@ -113,33 +113,9 @@ distributing this software or its derivatives. "font-style":"{\"weight\":\"light\"}" } }, - "textselectiontoolbar": - { - "enable-overshoot":false, - "scroll-view": - { - "overshoot-animation-speed":120.0, - "overshoot-size":[480.0,42.0] - } - }, "scrollview": { - "overshoot-effect-color":[0.24,0.72,0.8], - "overshoot-animation-speed":120.0, - "overshoot-size":[480.0,42.0], - "scroll-bar-padding":[8.0,6.0] - }, - "itemview": - { - "overshoot-effect-color":[0.24,0.72,0.8], - "overshoot-animation-speed":120.0, - "overshoot-size":[480.0,42.0] - }, - "scrollbar": - { - "indicator-show-duration":0.25, - "indicator-hide-duration":0.25, - "color":[0.24,0.72,0.8,1.0] + "overshoot-effect-color":"B018" } } } diff --git a/dali-toolkit/styles/480x800/images/cursor_handler_drop_center.png b/dali-toolkit/styles/480x800/images/cursor_handler_drop_center.png deleted file mode 100644 index a9a2b9ebc642a10454032011fce3be45229daad2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3231 zcmV;Q3}Ew#P)Oz@Z0f2-7z;ux~O9+4z06=<WDR*FRcSTFz- zW=q650N5=6FiBTtNC2?60Km==3$g$R3;-}uh=nNt1bYBr$Ri_o0EC$U6h`t_Jn<{8 z5a%iY0C<_QJh>z}MS)ugEpZ1|S1ukX&Pf+56gFW3VVXcL!g-k)GJ!M?;PcD?0HBc- z5#WRK{dmp}uFlRjj{U%*%WZ25jX z{P*?XzTzZ-GF^d31o+^>%=Ap99M6&ogks$0k4OBs3;+Bb(;~!4V!2o<6ys46agIcq zjPo+3B8fthDa9qy|77CdEc*jK-!%ZRYCZvbku9iQV*~a}ClFY4z~c7+0P?$U!PF=S z1Au6Q;m>#f??3%Vpd|o+W=WE9003S@Bra6Svp>fO002awfhw>;8}z{#EWidF!3EsG z3;bXU&9EIRU@z1_9W=mEXoiz;4lcq~xDGvV5BgyU zp1~-*fe8db$Osc*A=-!mVv1NJjtCc-h4>-CNCXm#Bp}I%6j35eku^v$Qi@a{RY)E3 zJ#qp$hg?Rwkvqr$GJ^buyhkyVfwECO)C{#lxu`c9ghrwZ&}4KmnvWKso6vH!8a<3Q zq36)6Xb;+tK10Vaz~~qUGsJ8#F2=(`u{bOVlV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+q;9dL%E~B zJh;4Nr^(LEJ3myURP{Rblsw%57T)g973R8o)DE9*xN#~;4_o$q%o z4K@u`jhx2fBXC4{U8Qn{*%*B$Ge=nny$HAYq{=vy|sI0 z_vss+H_qMky?OB#|JK!>IX&II^LlUh#rO5!7TtbwC;iULyV-Xq?ybB}ykGP{?LpZ? z-G|jbTmIbG@7#ZCz;~eY(cDM(28Dyq{*m>M4?_iynUBkc4TkHUI6gT!;y-fz>HMcd z&t%Ugo)`Y2{>!cx7B7DI)$7;J(U{Spm-3gBzioV_{p!H$8L!*M!p0uH$#^p{Ui4P` z?ZJ24cOCDe-w#jZd?0@)|7iKK^;6KN`;!@ylm7$*nDhK&GcDTy000JJOGiWi00000 z0Qp0^e*gdg32;bRa{vGf6951U69E94oEQKA00(qQO+^Ra3Iz@TB@;*$ga7~m(Md!> zRA}Dqm_2J1K@^7Ha|5|43>ZO#1cK(HvJovT3{e|fEwqTiE~ygy3FbHW59|yURu-`` zfwUh1S%7u`-FR(mo%6N*Sb{ z&^gbGE_Ep@=bf?#Tr0BJE4t@BU`3R=4+MJSY0;!Az!tsp8K}mHDONR_mvl2iJ69zw z#|X$GjMk8(9ZBPnI_amR2{ZeZdc>YZl#-+oNlQsb3@~6v(sb7Wmc z6^%RpW_<`}3u2>Z9q=G!Dn35h^NmKM2OgyqyPIP|%%q%Sza>jU2@`Qi`ogB9Hl%wViZj|AzRyOTGvWAxuj8D5=`+ z(y0Z9l5UvUr{w#w5W->zfo4~SEEa9Exe_4-SBiS(u>c%&A#?yN6#b-X3U~|D+YqW} z-%iDj!*Udylr$&lo}}xNu4J!%WW{D((rYu@mE$;$<2a7vIF92uj^p$te*rLrD=XKk Rhpqqs002ovPDHLkV1g^k`1t?; diff --git a/dali-toolkit/styles/480x800/images/selection_handle_drop_left.png b/dali-toolkit/styles/480x800/images/selection_handle_drop_left.png deleted file mode 100644 index d9ed8b8906cce59cb194dcb6d71251c244e0407b..0000000000000000000000000000000000000000 GIT binary patch literal 0 Hcm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A00(qQO+^Ra3Iz=oFYQD36aWAL&`Cr= zRA}Dq*-wZ~Q5*;G&l_VbNGPSrzXcX*V&Tum!b)spfs$e+k;N=6l>8~#va?Y3!%9iE z$bzInA;khqQ$i>|o2#aon&G{7=A8FB-+HV2-uL$DoO|y%_q8HIpJf1haD1?jP)l(P zC$R?l0k5ILD+lY(UHyf&#aI0_*M=9aT$*~g_SmP!?@Ml4ZAk4OUNeN#>#GAw7D~a zdsyD>;#TH`^I|;1+Egp(oVk<=mV4w@;|+!q_5aQ}awihP;8RZAp~U^~a^cqf-B2dX zi(I&Eb8wFFT)5#mILDJ*xMhj^zu|E%+?T}t_wg$i?tS9^n>ioi8}KSo_YbVVM6Qv0 zjhBhKZ(t(#+VX0G&hI#1!ovAFo_D$P3_g^y*uAoilZ|3jBX=0d_T`v8CBPEWu~I zZLZNVJeWESOM8csGz0oL6<2W;S8)|raTQl_6<2W;S8)|raTQl_6*qhS0JLBJj8r-2 Q#{d8T07*qoM6N<$f}qL~PXGV_ diff --git a/dali-toolkit/styles/480x800/images/selection_handle_drop_right.png b/dali-toolkit/styles/480x800/images/selection_handle_drop_right.png deleted file mode 100644 index f66b26b4acfc76b251d8b46ac45bdb1369ba47d5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3236 zcmV;V3|sSwP)Oz@Z0f2-7z;ux~O9+4z06=<WDR*FRcSTFz- zW=q650N5=6FiBTtNC2?60Km==3$g$R3;-}uh=nNt1bYBr$Ri_o0EC$U6h`t_Jn<{8 z5a%iY0C<_QJh>z}MS)ugEpZ1|S1ukX&Pf+56gFW3VVXcL!g-k)GJ!M?;PcD?0HBc- z5#WRK{dmp}uFlRjj{U%*%WZ25jX z{P*?XzTzZ-GF^d31o+^>%=Ap99M6&ogks$0k4OBs3;+Bb(;~!4V!2o<6ys46agIcq zjPo+3B8fthDa9qy|77CdEc*jK-!%ZRYCZvbku9iQV*~a}ClFY4z~c7+0P?$U!PF=S z1Au6Q;m>#f??3%Vp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|a1JhFRXy)kQCN+um{IRBQ4!dN zJN1@V6oET%q5Ni1cS?!RNN>e?G&iXJ??UZZ%IY7=fNH`~?*$MGRmfjhAv z2XQ2sf$cb$lUUxQC~y;Ig}|}(yh7mU=#(un=7ra(30#}A*UuNJ30#q*SiYp#gu8PT z%TxSF@fnyG22z|%=*Uqlk5ZgW_<>SRVwsy_FZ?MdalFFo6r1qdoWyba*N@Z$KF>)U z*HRTYkcYPq+)q{DtsKN~uH2bPu@{Dyvc1ZU;InM$^kb?S2xl5tcVDHvR5NfAo?%|S zCl0U#-zxu1F$2HKru6H1=fBJ5A;0~3Ak{UIyEs*+x`xm@+z24$WzA+>#>N`ga~LOv zJDBp$gh6b^*&1fvp?}FsJp(K0!AVRVr}93O%e?--6N|FBs9!eOdZ}`dJIbuPf<+^d zSELNAWFhurLlqf0h#NSD$JJC;D)8s7?XpFvm9p)=U9#Ni2n>NCFa!o6Fa(Cc5Ez8O5EueOU=RXBUK?n?iAut36Aut4n hzz`UOzz~=}egen0d`{zprilOm002ovPDHLkV1j_)a+Cl7 diff --git a/dali-toolkit/styles/720x1280/images/selection_handle_drop_right.png b/dali-toolkit/styles/720x1280/images/selection_handle_drop_right.png deleted file mode 100644 index 75035bc4d0ed4949870b1baa8754f6bd63df5fe9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3459 zcmV-}4Se#6P)Oz@Z0f2-7z;ux~O9+4z06=<WDR*FRcSTFz- zW=q650N5=6FiBTtNC2?60Km==3$g$R3;-}uh=nNt1bYBr$Ri_o0EC$U6h`t_Jn<{8 z5a%iY0C<_QJh>z}MS)ugEpZ1|S1ukX&Pf+56gFW3VVXcL!g-k)GJ!M?;PcD?0HBc- z5#WRK{dmp}uFlRjj{U%*%WZ25jX z{P*?XzTzZ-GF^d31o+^>%=Ap99M6&ogks$0k4OBs3;+Bb(;~!4V!2o<6ys46agIcq zjPo+3B8fthDa9qy|77CdEc*jK-!%ZRYCZvbku9iQV*~a}ClFY4z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xSvv8xpm-#bRun&IgT*pqsSEaBUgbx zCsNa$Tm@cDvyn=^$g04+8Z7V z&&4e)>u@a-SdM>l?m)_SMK3$h9T^d zDep@r9Kh}w?8GD3fd6t8So^?i(U&-;%(eU#<8Lo z z);gcB>@E62K?n?iAut36Aut4nzz`UOzz`S$LtqdBLtqFDfk6lifgvyi1|cv6hQJUQ lguoCO0z+UB0z+VWyaM3h!E0rajSc_+002ovPDHLkV1mEWYWDyD diff --git a/dali-toolkit/styles/file.list b/dali-toolkit/styles/file.list index 6c329e9..8e49fbe 100644 --- a/dali-toolkit/styles/file.list +++ b/dali-toolkit/styles/file.list @@ -2,6 +2,3 @@ dali_toolkit_style_files =\ $(toolkit_styles_dir)/*.json - -dali_toolkit_style_images =\ - $(toolkit_style_images_dir)/*.png diff --git a/dali-toolkit/styles/images-common/core_contextual_popup_bg_stroke_color.9.png b/dali-toolkit/styles/images-common/core_contextual_popup_bg_stroke_color.9.png deleted file mode 100644 index 136abcec428fe9f2785ffa3bb9b70ca03a21d6d2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 459 zcmeAS@N?(olHy`uVBq!ia0vp^+91rq1|%QG79IdnY)RhkE)4%caKYZ?lYt_f1s;*b z3=G`DAk4@xYmNj^kiEpy*OmP~rywVvh-2fFwG0f55uPrNArXh)-rSgVC_v=c$NHEY zwp{HFi(PE-E(K?+H7?!VyXgJIi{ge}Y3{GDNqNKy`HL4zyK?0!dp?k{aBe%GFMm?? zyW9@{lRJyoMtwVUIG5F;u0?kK2A2ox=VsN{zUTB-dSh|mqwSq*zF#LjeBfdGlilFE zU6B7Y9`+dZSx(MUM(H}SWvvps-=v(2aFSws^Kct)nRESAr|KMU!JPiJjQKCt^Ozm# zV@)}@!Y98`N20UA<%VHH>Aw=z2NRhUeNP4X*L*lRwUbZ+;QplR=!-VDYKP%{aYVUw>k&kw15p!EU2)gXZO+#P|x<2Pd49 z{_!!(?C(*(&pt~@fw3=t-hsop>FHd?YL^n@IW`@ROY_-e+&qlgPpEeSfEgWr;B5V#O2)c8#$Q*1zH|Pitc>j z!{ROAZMxTL%|WRnN0{Cm2$*pGiLL(y`>3??wwq2?p{kw%zESIpHXpq5%$X3R S-2V({H-o3EpUXO@geCxnTT)K| diff --git a/dali-toolkit/styles/images-common/selection_handle_ball_left.png b/dali-toolkit/styles/images-common/selection_handle_ball_left.png deleted file mode 100755 index 4d29039aa072ba33fae1a7dfde1c856cfca4b674..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 546 zcmV+-0^R+IP)u~@80k26! zK~!ko?bxwS6j2m_;r|Q`l3)j&8jS@;-#|-<`UD1F!RXUyL5RMFu?HlC65TBnBlZ?j z!*6pJH<9e_;O@?iIbXSx+5Iz2?tN}FTgJ&JaFo+or zdO;LAEXt}l^Y7088sOM(`{HQ4Cqyaux6!fVn zyMtQnhI$A1Qo(91aJPwwV_>g>tMf4;jt7tZn+k$nGq_D<6L&QHUedt}+JlHVYXBnR z40ze$)p=DK{@Mb)>)?I*?Wo;qXWO7rQJriQ$3?BGhck>hR9D;1fv(MS*w7|yV@kKM zuWn3dP5(2n+G{zmvYhjL+`#H$8+65y-qSMDTLW$a*URBwz)4x?c7XSjj`UJWDW#NB kN-3q3Qc5YMl>P_50o!d;l@WCcMF0Q*07*qoM6N<$g32!Rvj6}9 diff --git a/dali-toolkit/styles/images-common/selection_handle_ball_right.png b/dali-toolkit/styles/images-common/selection_handle_ball_right.png deleted file mode 100755 index 561e525cd25e9e2c3f7dc9505196ceff8b19351c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 545 zcmV++0^a?JP)D`J4a%0j^0z zK~!ko?byFgR6!KS@$b1bNP-=d8jJ-R-#|+U@dZrq8PuoIf)ITTV-H9OrMg=fj96=- zRwVGX8Dyg??&2;pCg)S$KglmMcjnGHp$ZTY!3fkPU=6qj+ybrx^X2w8;3Lojwt!a= z@quwz{NhLg9U&W;sGT~PO&o;`J8 zq(CK1-|6cQ4K)}@ol|$cJiF@Ld4V>)e49f9mDNbT#yWI}vf*4P2}h z24ER@0MOBnN54*4Z2~u28leEzS_%Ykx3xgGTl$6ozO)wTsI@7h13ovD=X(cyYADcQ z2fS-2(A%z52d&r+^#<_1?3DF?9T9N=>@+YsuOs5%blE>^Akfp(9~z~IdsEIO^$%zf zaSS}JI66;ChTkfX7ZuLa&(A9w>z6@8Le(u4{}5_X-JfEZeRXl%HqDhP&4v+ztxjkP z`|9ds_Vlxc)y|j=E6Y0%M{QWe1;Q->_e)D}8Mp>qEw{e{hh?MN0$z^Y(n~3&lu}A5 jrIb=iDW#NB`j7np88l#W2!jIo00000NkvXXu0mjfAC%&u diff --git a/doc/dali-toolkit_doc.h b/doc/dali-toolkit_doc.h index 477a0f3..6e3be9c 100644 --- a/doc/dali-toolkit_doc.h +++ b/doc/dali-toolkit_doc.h @@ -1,23 +1,6 @@ #ifndef __DALI_TOOLKIT_DOC_H__ #define __DALI_TOOLKIT_DOC_H__ -/* - * Copyright (c) 2015 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. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - */ - /** * @defgroup dali DALi * @ingroup CAPI_UI_FRAMEWORK @@ -25,141 +8,65 @@ * @brief DALi is a cross-platform 3D UI Toolkit for embedded systems. * * @section dali-overview Overview - * * DALi's 3D user interface engine enables you to create rich and high-performance * UI applications. DALi is based on OpenGL ES 2.0, but provides a clean * cross-platform C++ framework. * This means that you can use high-level DALi APIs instead of accessing * low-level OpenGL APIs directly. + *
    + *
  • DALi Core: This module provides scene graph-based rendering, animation, and event handling.
  • + *
  • DALi Adaptor: This module is a platform adaptation layer.
  • + *
  • DALi Toolkit: This module provides UI components and various effects on top of the dali-core.
  • + *
* - * DALi consists of the following modules: - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - *
ModuleDescription
@ref dali_coreDALi Core provides core functionalities such as scene graph-based rendering, animation, and event handling.
@ref dali_adaptorDALi Adaptor is a platform adaptation layer.
@ref dali_toolkitDALi Toolkit provides UI components and various effects on top of the DALi Core.
- * - * The layer diagram for DALi modules is shown below: - * @image html dali-modules.png "Figure: DALi modules" - * - * @defgroup dali_toolkit DALi Toolkit - * - * @brief DALi Toolkit provides UI components and various effects on top of the DALi Core. - * - * @section dali_core_overview Overview - * - * DALi Toolkit consists of the following groups of API: + * @defgroup dali-toolkit DALi Toolkit + * @ingroup dali * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - *
API GroupDescription
@ref dali_toolkit_controlsControls are interactive components for layouting the user interface.
@ref dali_toolkit_controls_alignmentAlignment is a container which provides an easy way to align other actors inside its boundary.
@ref dali_toolkit_controls_buttonsButton is a small object on UI that you can press.
@ref dali_toolkit_controls_gaussian_blur_viewGaussianBlurView provides a render process that blurs an image.
@ref dali_toolkit_controls_image_viewImageView is a control displying an image.
@ref dali_toolkit_controls_scroll_barScrollBar control.
@ref dali_toolkit_controls_scrollableScrollable container controls.
@ref dali_toolkit_controls_item_viewItemView class is a scrollable container that can contain many items.
@ref dali_toolkit_controls_scroll_viewScrollView class provides scrollable view which contains actors and can be scrolled automatically or manually by panning.
@ref dali_toolkit_controls_table_viewTableView class is a layout container for aligning child actors in a grid like layout.
@ref dali_toolkit_controls_text_controlsControls for displaying text or text input.
@ref dali_toolkit_managersSingleton classes for managing application-wide functionalities.
+ * @brief This module provides UI components and various effects on top of the dali-core. * - * @ingroup dali * @{ - * @defgroup dali_toolkit_controls Controls + * @defgroup dali-toolkit-accessibility-manager Accessibility Manager + * @brief AccessibilityManager manages a accessibility focus chain. + + * @defgroup dali-toolkit-controls Controls * @brief Controls are interactive components for layouting the user interface. * @{ - * @defgroup dali_toolkit_controls_alignment Alignment + * @defgroup dali-toolkit-controls-alignment Alignment * @brief Alignment is a container which provides an easy way to align other actors inside its boundary. - * @defgroup dali_toolkit_controls_buttons Buttons + * @defgroup dali-toolkit-controls-buttons Buttons * @brief Button is a small object on UI that you can press. - * @defgroup dali_toolkit_controls_gaussian_blur_view Gaussian Blur View + * @defgroup dali-toolkit-controls-gaussian-blur-view Gaussian Blur View * @brief GaussianBlurView provides a render process that blurs an image. - * @defgroup dali_toolkit_controls_image_view Image View + * @defgroup dali-toolkit-controls-image-view Image View * @brief ImageView is a control displying an image. - * @defgroup dali_toolkit_controls_scroll_bar Scroll Bar + * @defgroup dali-toolkit-controls-scroll-bar Scroll Bar * @brief ScrollBar control. - * @defgroup dali_toolkit_controls_scrollable Scrollable + * @defgroup dali-toolkit-controls-scrollable Scrollable * @brief Scrollable container controls. * @{ - * @defgroup dali_toolkit_controls_item_view Item View + * @defgroup dali-toolkit-controls-item-view Item View * @brief ItemView class is a scrollable container that can contain many items. - * @defgroup dali_toolkit_controls_scroll_view Scroll View + * @defgroup dali-toolkit-controls-scroll-view Scroll View * @brief ScrollView class provides scrollable view which contains actors and can be scrolled automatically or manually by panning. * @} - * @defgroup dali_toolkit_controls_table_view Table View + * @defgroup dali-toolkit-controls-table-view Table View * @brief TableView class is a layout container for aligning child actors in a grid like layout. - * @defgroup dali_toolkit_controls_text_controls Text Controls + * @defgroup dali-toolkit-controls-text-controls Text Controls * @brief Controls for displaying text or text input. * @} - - * @defgroup dali_toolkit_managers Managers - * @brief Singleton classes for managing application-wide functionalities. + * @defgroup dali-toolkit-focus-manager Focus Manager + * @brief Classes for handling keyboard navigation and maintaining the two dimensional keyboard focus chain. * @} */ diff --git a/doc/images/dali-modules.png b/doc/images/dali-modules.png deleted file mode 100755 index d85303ccbd6b39bf36a5491734096e8a72187b0d..0000000000000000000000000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