From 6d7c2809a5217a107c649a76e6c8ec508ce054fd Mon Sep 17 00:00:00 2001 From: Seongjun Yim Date: Thu, 16 May 2013 00:29:31 +0900 Subject: [PATCH] fix text selection bug on INPUT, TEXTAREA tag Change-Id: I8304356d3e3baec51154f7e05f234004e26c75f4 Signed-off-by: Seongjun Yim --- src/controls/FWebCtrl_GestureState.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/controls/FWebCtrl_GestureState.cpp b/src/controls/FWebCtrl_GestureState.cpp index b736649..ccf94aa 100755 --- a/src/controls/FWebCtrl_GestureState.cpp +++ b/src/controls/FWebCtrl_GestureState.cpp @@ -158,8 +158,15 @@ _TapGestureState::OnTouchReleased(const _Control& source, const _TouchInfo& touc if (tagName.Equals(L"INPUT", false) || tagName.Equals(L"TEXTAREA", false)) { - SetGestureEvent(gestureEvent, EWK_GESTURE_LONG_PRESS, absPoint, Point(0, 0), 0.0, 1); - pSmartData->api->gesture_end(const_cast(pSmartData), &gestureEvent); + Eina_Rectangle leftHandle; + Eina_Rectangle rightHandle; + + ewk_view_text_selection_range_get(__pWebCore->GetWebNativeNode(), &leftHandle, &rightHandle); + if ((rightHandle.x == 0) && (rightHandle.y == 0)) + { + SetGestureEvent(gestureEvent, EWK_GESTURE_LONG_PRESS, absPoint, Point(0, 0), 0.0, 1); + pSmartData->api->gesture_end(const_cast(pSmartData), &gestureEvent); + } } } else if (__doubleTapped) -- 2.7.4