From 4f7683d0c955776f84277e92842b3cedbda9da21 Mon Sep 17 00:00:00 2001 From: Jiyun Yang Date: Thu, 22 Nov 2018 14:46:46 +0900 Subject: [PATCH] Revert "[Tizen] Relayout again for LTR / RTL order when layout direction is changed." This reverts commit 7a468f3e7d88baee85125d11e8f02e1f24b273d3. --- dali-toolkit/internal/controls/text-controls/text-editor-impl.cpp | 7 ------- dali-toolkit/internal/controls/text-controls/text-editor-impl.h | 7 ------- dali-toolkit/internal/controls/text-controls/text-field-impl.cpp | 7 ------- dali-toolkit/internal/controls/text-controls/text-field-impl.h | 7 ------- dali-toolkit/internal/controls/text-controls/text-label-impl.cpp | 7 ------- dali-toolkit/internal/controls/text-controls/text-label-impl.h | 7 ------- dali-toolkit/internal/text/text-controller.cpp | 8 -------- dali-toolkit/internal/text/text-controller.h | 5 ----- 8 files changed, 55 deletions(-) mode change 100755 => 100644 dali-toolkit/internal/controls/text-controls/text-label-impl.h diff --git a/dali-toolkit/internal/controls/text-controls/text-editor-impl.cpp b/dali-toolkit/internal/controls/text-controls/text-editor-impl.cpp index d125510..b065e99 100755 --- a/dali-toolkit/internal/controls/text-controls/text-editor-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-editor-impl.cpp @@ -1247,8 +1247,6 @@ void TextEditor::OnInitialize() Dali::LayoutDirection::Type layoutDirection = static_cast( self.GetProperty( Dali::Actor::Property::LAYOUT_DIRECTION ).Get() ); mController->SetLayoutDirection( layoutDirection ); - self.LayoutDirectionChangedSignal().Connect( this, &TextEditor::OnLayoutDirectionChanged ); - // Forward input events to controller EnableGestureDetection( static_cast( Gesture::Tap | Gesture::Pan | Gesture::LongPress ) ); GetTapGestureDetector().SetMaximumTapsRequired( 2 ); @@ -1295,11 +1293,6 @@ void TextEditor::OnInitialize() self.Add( mStencil ); } -void TextEditor::OnLayoutDirectionChanged( Dali::Actor actor, Dali::LayoutDirection::Type type ) -{ - mController->UpdateLayoutDirectionChanged( type ); -} - void TextEditor::OnStyleChange( Toolkit::StyleManager styleManager, StyleChange::Type change ) { DALI_LOG_INFO( gLogFilter, Debug::Verbose, "TextEditor::OnStyleChange\n"); diff --git a/dali-toolkit/internal/controls/text-controls/text-editor-impl.h b/dali-toolkit/internal/controls/text-controls/text-editor-impl.h index 24a5ddc..5595e18 100755 --- a/dali-toolkit/internal/controls/text-controls/text-editor-impl.h +++ b/dali-toolkit/internal/controls/text-controls/text-editor-impl.h @@ -261,13 +261,6 @@ private: // Implementation void OnScrollIndicatorAnimationFinished( Animation& animation ); /** - * @brief Callbacks when the layout direction changes - * @param[in] actor The actor whose layoutDirection is changed. - * @param[in] type The layoutDirection. - */ - void OnLayoutDirectionChanged( Dali::Actor actor, Dali::LayoutDirection::Type type ); - - /** * Construct a new TextEditor. */ TextEditor(); 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 cc1df34..655c335 100755 --- a/dali-toolkit/internal/controls/text-controls/text-field-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-field-impl.cpp @@ -1307,8 +1307,6 @@ void TextField::OnInitialize() Dali::LayoutDirection::Type layoutDirection = static_cast( self.GetProperty( Dali::Actor::Property::LAYOUT_DIRECTION ).Get() ); mController->SetLayoutDirection( layoutDirection ); - self.LayoutDirectionChangedSignal().Connect( this, &TextField::OnLayoutDirectionChanged ); - // Forward input events to controller EnableGestureDetection( static_cast( Gesture::Tap | Gesture::Pan | Gesture::LongPress ) ); GetTapGestureDetector().SetMaximumTapsRequired( 2 ); @@ -1341,11 +1339,6 @@ void TextField::OnInitialize() } } -void TextField::OnLayoutDirectionChanged( Dali::Actor actor, Dali::LayoutDirection::Type type ) -{ - mController->UpdateLayoutDirectionChanged( type ); -} - void TextField::OnStyleChange( Toolkit::StyleManager styleManager, StyleChange::Type change ) { DALI_LOG_INFO( gLogFilter, Debug::Verbose, "TextField::OnStyleChange\n"); diff --git a/dali-toolkit/internal/controls/text-controls/text-field-impl.h b/dali-toolkit/internal/controls/text-controls/text-field-impl.h index 7adcb8f..495f789 100755 --- a/dali-toolkit/internal/controls/text-controls/text-field-impl.h +++ b/dali-toolkit/internal/controls/text-controls/text-field-impl.h @@ -242,13 +242,6 @@ private: // Implementation void OnIdleSignal(); /** - * @brief Callbacks when the layout direction changes - * @param[in] actor The actor whose layoutDirection is changed. - * @param[in] type The layoutDirection. - */ - void OnLayoutDirectionChanged( Dali::Actor actor, Dali::LayoutDirection::Type type ); - - /** * Construct a new TextField. */ TextField(); 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 eddec25..376709a 100755 --- a/dali-toolkit/internal/controls/text-controls/text-label-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-label-impl.cpp @@ -888,17 +888,10 @@ void TextLabel::OnInitialize() Dali::LayoutDirection::Type layoutDirection = static_cast( self.GetProperty( Dali::Actor::Property::LAYOUT_DIRECTION ).Get() ); mController->SetLayoutDirection( layoutDirection ); - self.LayoutDirectionChangedSignal().Connect( this, &TextLabel::OnLayoutDirectionChanged ); - Layout::Engine& engine = mController->GetLayoutEngine(); engine.SetCursorWidth( 0u ); // Do not layout space for the cursor. } -void TextLabel::OnLayoutDirectionChanged( Dali::Actor actor, Dali::LayoutDirection::Type type ) -{ - mController->UpdateLayoutDirectionChanged( type ); -} - void TextLabel::OnStyleChange( Toolkit::StyleManager styleManager, StyleChange::Type change ) { DALI_LOG_INFO( gLogFilter, Debug::Verbose, "TextLabel::OnStyleChange\n"); diff --git a/dali-toolkit/internal/controls/text-controls/text-label-impl.h b/dali-toolkit/internal/controls/text-controls/text-label-impl.h old mode 100755 new mode 100644 index b9f3bf8..85e94ab --- a/dali-toolkit/internal/controls/text-controls/text-label-impl.h +++ b/dali-toolkit/internal/controls/text-controls/text-label-impl.h @@ -119,13 +119,6 @@ private: // from TextScroller */ virtual void ScrollingFinished(); - /** - * @brief Callbacks when the layout direction changes - * @param[in] actor The actor whose layoutDirection is changed. - * @param[in] type The layoutDirection. - */ - void OnLayoutDirectionChanged( Dali::Actor actor, Dali::LayoutDirection::Type type ); - private: // Implementation /** diff --git a/dali-toolkit/internal/text/text-controller.cpp b/dali-toolkit/internal/text/text-controller.cpp index 6a32646..6c1bf75 100755 --- a/dali-toolkit/internal/text/text-controller.cpp +++ b/dali-toolkit/internal/text/text-controller.cpp @@ -4078,14 +4078,6 @@ bool Controller::ShouldClearFocusOnEscape() const return mImpl->mShouldClearFocusOnEscape; } -void Controller::UpdateLayoutDirectionChanged( Dali::LayoutDirection::Type type ) -{ - mImpl->mLayoutDirection = type; - mImpl->mOperationsPending = static_cast( mImpl->mOperationsPending | - BIDI_INFO ); - mImpl->RequestRelayout(); -} - // private : Private contructors & copy operator. Controller::Controller() diff --git a/dali-toolkit/internal/text/text-controller.h b/dali-toolkit/internal/text/text-controller.h index c3b8375..33f1f8f 100755 --- a/dali-toolkit/internal/text/text-controller.h +++ b/dali-toolkit/internal/text/text-controller.h @@ -1361,11 +1361,6 @@ public: // Text-input Event Queuing. */ bool ShouldClearFocusOnEscape() const; - /** - * @brief UpdateLayoutDirectionChanged - */ - void UpdateLayoutDirectionChanged( Dali::LayoutDirection::Type type ); - protected: // Inherit from Text::Decorator::ControllerInterface. /** -- 2.7.4