Move closing clipboard code before open keypad
authorSangYong Park <sy302.park@samsung.com>
Thu, 9 May 2013 12:12:14 +0000 (21:12 +0900)
committerGerrit Code Review <gerrit2@kim11>
Thu, 9 May 2013 12:40:32 +0000 (21:40 +0900)
[Title] Move closing clipboard code before open keypad
[Issue#] N_SE-37944
[Problem] Clipboard did closed when device was rotated
[Cause] editState was notified when device was rotated
[Solution] Move closing clipboard code

Change-Id: I4876d98947b60dcb59334ad647161da2e299c23a

Source/WebKit2/UIProcess/efl/InputMethodContextEfl.cpp

index 8ff196f..5c25dc7 100755 (executable)
@@ -328,13 +328,9 @@ void InputMethodContextEfl::updateTextInputState()
     if (editor.shouldIgnoreCompositionSelectionChange)
         return;
 
-    if (editor.isContentEditable && m_useInputMethod) {
-#if ENABLE(TIZEN_WEBKIT2_CONTEXT_MENU_CLIPBOARD)
-        if (m_viewImpl->pageClient->isClipboardWindowOpened())
-            m_viewImpl->pageClient->closeClipboardWindow();
-#endif
+    if (editor.isContentEditable && m_useInputMethod)
         showIMFContext(editor);
-    else
+    else
         hideIMFContext();
 
     if (m_context)
@@ -559,6 +555,11 @@ void InputMethodContextEfl::showIMFContext(const EditorState& editor)
         return;
     }
 
+#if ENABLE(TIZEN_WEBKIT2_CONTEXT_MENU_CLIPBOARD)
+    if (m_viewImpl->pageClient->isClipboardWindowOpened())
+        m_viewImpl->pageClient->closeClipboardWindow();
+#endif
+
     ecore_imf_context_reset(m_context.get());
     ecore_imf_context_focus_in(m_context.get());
     ecore_imf_context_input_panel_show(m_context.get());