X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=dali-toolkit%2Finternal%2Ftext%2Ftext-controller.cpp;h=04071474dc354184e1708cbf4759e49f79963c21;hp=76c7fdd0654e12f511052ae979cf6b0c4d342b43;hb=590ede8c5f4771821ff5ac3f3acef0d189525008;hpb=271110063e8b896a45d7c9116cf4ad53585933bd diff --git a/dali-toolkit/internal/text/text-controller.cpp b/dali-toolkit/internal/text/text-controller.cpp index 76c7fdd..0407147 100755 --- a/dali-toolkit/internal/text/text-controller.cpp +++ b/dali-toolkit/internal/text/text-controller.cpp @@ -2143,7 +2143,7 @@ bool Controller::CheckForTextFit( float pointSize, Size& layoutSize ) void Controller::FitPointSizeforLayout( Size layoutSize ) { const OperationsMask operations = mImpl->mOperationsPending; - if( NO_OPERATION != ( UPDATE_LAYOUT_SIZE & operations ) ) + if( NO_OPERATION != ( UPDATE_LAYOUT_SIZE & operations ) || mImpl->mTextFitContentSize != layoutSize ) { bool actualellipsis = mImpl->mModel->mElideEnabled; float minPointSize = mImpl->mTextFitMinSize; @@ -2454,6 +2454,9 @@ Toolkit::DevelText::TextDirection::Type Controller::GetTextDirection() // Clear the update info. This info will be set the next time the text is updated. mImpl->mTextUpdateInfo.Clear(); + // FullRelayoutNeeded should be true because DoRelayout is MAX_FLOAT, MAX_FLOAT. + mImpl->mTextUpdateInfo.mFullRelayoutNeeded = true; + mImpl->mUpdateTextDirection = false; } @@ -3711,11 +3714,7 @@ bool Controller::RemoveText( int cursorOffset, // it means all texts should be removed and all Preedit variables should be initialized. if( ( currentText.Count() - numberOfCharacters == 0 ) && ( cursorIndex == 0 ) ) { - if( mImpl->mEventData ) - { - mImpl->mEventData->mPreEditStartPosition = 0; - mImpl->mEventData->mPreEditLength = 0; - } + mImpl->ClearPreEditFlag(); } // Updates the text style runs by removing characters. Runs with no characters are removed. @@ -3732,6 +3731,11 @@ bool Controller::RemoveText( int cursorOffset, mImpl->mEventData->mScrollAfterDelete = true; + if( EventData::INACTIVE == mImpl->mEventData->mState ) + { + mImpl->ChangeState( EventData::EDITING ); + } + DALI_LOG_INFO( gLogFilter, Debug::General, "Controller::RemoveText %p removed %d\n", this, numberOfCharacters ); removed = true; } @@ -4297,6 +4301,11 @@ bool Controller::ShouldClearFocusOnEscape() const return mImpl->mShouldClearFocusOnEscape; } +Actor Controller::CreateBackgroundActor() +{ + return mImpl->CreateBackgroundActor(); +} + // private : Private contructors & copy operator. Controller::Controller()