From: Taeyun An Date: Thu, 30 May 2013 01:52:11 +0000 (+0900) Subject: Show vertical mode context menu at the link or image when cursor is in editable contents. X-Git-Tag: submit/tizen_2.2/20130714.131554~9 X-Git-Url: http://review.tizen.org/git/?p=framework%2Fweb%2Fwebkit-efl.git;a=commitdiff_plain;h=80a3616e9c436abe9d2ec9f95c940dd93766aee3 Show vertical mode context menu at the link or image when cursor is in editable contents. [Title] Show horizontal mode context menu at the link or image when cursor is in editable contents. [Issue#] N/A [Problem] Horizontal mode context menu is shown at the link or image when try to show context menu in editable content. [Cause] Now just checking EditorState [Solution] Change checking condition code Change-Id: I7a9d12a95d0b834acf5f8e17e6212ffa992e5853 --- diff --git a/Source/WebKit2/UIProcess/tizen/WebContextMenuProxyTizen.cpp b/Source/WebKit2/UIProcess/tizen/WebContextMenuProxyTizen.cpp index 5cf3d61..790e513 100755 --- a/Source/WebKit2/UIProcess/tizen/WebContextMenuProxyTizen.cpp +++ b/Source/WebKit2/UIProcess/tizen/WebContextMenuProxyTizen.cpp @@ -136,12 +136,19 @@ void WebContextMenuProxyTizen::createEflMenu(const VectorisTextSelectionMode()) + m_pageClientImpl->setIsTextSelectionMode(true); + elm_object_style_set(m_popup,"copypaste"); + elm_ctxpopup_horizontal_set(m_popup, EINA_TRUE); + elm_ctxpopup_direction_priority_set(m_popup, ELM_CTXPOPUP_DIRECTION_UP, ELM_CTXPOPUP_DIRECTION_UP, ELM_CTXPOPUP_DIRECTION_UP, ELM_CTXPOPUP_DIRECTION_UP); + } +#endif } static void contextMenuPopupDismissedCallback(void* data, Evas_Object* obj, void* eventInfo) @@ -214,16 +231,6 @@ void WebContextMenuProxyTizen::showContextMenu(const WebCore::IntPoint& position popupPosition.setX(popupPosition.x() + webViewX); popupPosition.setY(popupPosition.y() + webViewY); -#if ENABLE(TIZEN_WEBKIT2_TEXT_SELECTION) - if (m_pageClientImpl->isTextSelectionMode()) { - elm_object_style_set(m_popup,"copypaste"); - elm_ctxpopup_horizontal_set(m_popup, EINA_TRUE); - elm_ctxpopup_direction_priority_set(m_popup, ELM_CTXPOPUP_DIRECTION_UP, ELM_CTXPOPUP_DIRECTION_UP, ELM_CTXPOPUP_DIRECTION_UP, ELM_CTXPOPUP_DIRECTION_UP); - - m_pageClientImpl->changeContextMenuPosition(popupPosition); - } -#endif - evas_object_move(m_popup, popupPosition.x(), popupPosition.y()); evas_object_show(m_popup);