From: Taeyun An Date: Thu, 10 Oct 2013 12:45:10 +0000 (+0900) Subject: Prevent to show context menu after paste X-Git-Tag: 2.2.1_release~99 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7554128c2dc545d72971484d829411d566218158;p=framework%2Fweb%2Fwebkit-efl.git Prevent to show context menu after paste [Title] Prevent to show context menu after paste [Issue#] N_SE-53993 [Problem] Context menu is appearing after paste operation via selection menu [Cause] Condition is wrong related context menu hide [Solution] Prevent to show context menu after paste Change-Id: I25177afd82f5e08bc57916437d094bef4cdb984f --- diff --git a/Source/WebKit2/UIProcess/API/efl/PageClientImpl.cpp b/Source/WebKit2/UIProcess/API/efl/PageClientImpl.cpp index 754a381..53baa39 100755 --- a/Source/WebKit2/UIProcess/API/efl/PageClientImpl.cpp +++ b/Source/WebKit2/UIProcess/API/efl/PageClientImpl.cpp @@ -394,14 +394,6 @@ void PageClientImpl::didChangeViewportProperties(const WebCore::ViewportAttribut double scaleRatioBeforeRotation = m_scaleFactor / m_viewportConstraints.minimumScale; m_viewportConstraints = computeViewportConstraints(attributes); -#if ENABLE(TIZEN_GESTURE) - bool doubleTapEnabled = userScalable(); -#if ENABLE(TIZEN_WEBKIT2_TEXT_SELECTION) - doubleTapEnabled |= ewk_settings_select_word_automatically_get(ewk_view_settings_get(m_viewImpl->view())); -#endif - m_viewImpl->setDoubleTapEnabled(doubleTapEnabled); -#endif - // Initially, m_scaleFactor is not decided yet. // So, we should update visible content rect at here. if (!m_scaleFactor) { @@ -420,7 +412,11 @@ void PageClientImpl::didChangeViewportProperties(const WebCore::ViewportAttribut } #if ENABLE(TIZEN_GESTURE) - m_viewImpl->setDoubleTapEnabled(userScalable()); + bool doubleTapEnabled = userScalable(); +#if ENABLE(TIZEN_WEBKIT2_TEXT_SELECTION) + doubleTapEnabled |= ewk_settings_select_word_automatically_get(ewk_view_settings_get(m_viewImpl->view())); +#endif + m_viewImpl->setDoubleTapEnabled(doubleTapEnabled); #endif #if ENABLE(TIZEN_DLOG_SUPPORT) diff --git a/Source/WebKit2/UIProcess/API/efl/tizen/TextSelection.cpp b/Source/WebKit2/UIProcess/API/efl/tizen/TextSelection.cpp index 9464db1..97298df 100755 --- a/Source/WebKit2/UIProcess/API/efl/tizen/TextSelection.cpp +++ b/Source/WebKit2/UIProcess/API/efl/tizen/TextSelection.cpp @@ -563,7 +563,7 @@ void TextSelection::updateHandlesAndContextMenu(bool isShow, bool isScrolling) } const EditorState& editorState = m_viewImpl->page()->editorState(); - if (!isTextSelectionMode() && !editorState.selectionIsRange && editorState.isContentEditable) { + if (!editorState.selectionIsRange && editorState.isContentEditable) { setIsTextSelectionMode(false); return; } @@ -852,6 +852,11 @@ void TextSelection::showHandlesAndContextMenu() m_lastLeftHandleRect = leftRect; m_lastRightHandleRect = rightRect; + } else { + if (m_showTimer) { + ecore_timer_del(m_showTimer); + m_showTimer = 0; + } } }