From 714066000e082a6a1e5053d79c2e0c9cb5e163dd Mon Sep 17 00:00:00 2001 From: Agnelo Vaz Date: Thu, 11 Sep 2014 17:02:17 +0100 Subject: [PATCH] (TextInput) Moving selection handles when word selected does not de-select current word Change-Id: I94b1b363992197ae52ba507318d12c73caf14815 Signed-off-by: Agnelo Vaz --- .../internal/controls/text-input/text-input-impl.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/base/dali-toolkit/internal/controls/text-input/text-input-impl.cpp b/base/dali-toolkit/internal/controls/text-input/text-input-impl.cpp index 850431e..7600969 100644 --- a/base/dali-toolkit/internal/controls/text-input/text-input-impl.cpp +++ b/base/dali-toolkit/internal/controls/text-input/text-input-impl.cpp @@ -281,9 +281,9 @@ Dali::Toolkit::TextInput TextInput::New() TextInputPtr textInput(new TextInput()); // Pass ownership to CustomActor via derived handle Dali::Toolkit::TextInput handle(*textInput); + handle.SetName( "TextInput"); textInput->Initialize(); - return handle; } @@ -1152,6 +1152,7 @@ void TextInput::CreateActiveLayer() { Actor self = Self(); mActiveLayer = Layer::New(); + mActiveLayer.SetName ( "ActiveLayerActor" ); mActiveLayer.SetAnchorPoint( AnchorPoint::CENTER); mActiveLayer.SetParentOrigin( ParentOrigin::CENTER); @@ -1541,6 +1542,12 @@ void TextInput::OnLongPress(Dali::Actor actor, Dali::LongPressGesture longPress) { DALI_LOG_INFO( gLogFilter, Debug::General, "OnLongPress\n" ); + // Ignore longpress if in selection mode already + if( mHighlightMeshActor ) + { + return; + } + if(longPress.state == Dali::Gesture::Started) { // Start edit mode on long press @@ -2076,6 +2083,7 @@ void TextInput::SetUpTouchEvents() void TextInput::CreateTextViewActor() { mDisplayedTextView = Toolkit::TextView::New(); + mDisplayedTextView.SetName( "TextView "); mDisplayedTextView.SetMarkupProcessingEnabled( mMarkUpEnabled ); mDisplayedTextView.SetParentOrigin(ParentOrigin::TOP_LEFT); mDisplayedTextView.SetAnchorPoint(AnchorPoint::TOP_LEFT); -- 2.7.4