#if ENABLE(TIZEN_INPUT_TAG_EXTENSION)
if (editor.inputMethodHints == "date") {
- ewkViewInputPickerRequest(m_viewImpl->view(), EWK_INPUT_TYPE_DATE, editor.surroundingText);
+ showInputPicker(EWK_INPUT_TYPE_DATE, editor);
return;
} else if (editor.inputMethodHints == "datetime") {
- ewkViewInputPickerRequest(m_viewImpl->view(), EWK_INPUT_TYPE_DATETIME, editor.surroundingText);
+ showInputPicker(EWK_INPUT_TYPE_DATETIME, editor);
return;
} else if (editor.inputMethodHints == "datetime-local") {
- ewkViewInputPickerRequest(m_viewImpl->view(), EWK_INPUT_TYPE_DATETIMELOCAL, editor.surroundingText);
+ showInputPicker(EWK_INPUT_TYPE_DATETIMELOCAL, editor);
return;
} else if (editor.inputMethodHints == "month") {
- ewkViewInputPickerRequest(m_viewImpl->view(), EWK_INPUT_TYPE_MONTH, editor.surroundingText);
+ showInputPicker(EWK_INPUT_TYPE_MONTH, editor);
return;
} else if (editor.inputMethodHints == "time") {
- ewkViewInputPickerRequest(m_viewImpl->view(), EWK_INPUT_TYPE_TIME, editor.surroundingText);
+ showInputPicker(EWK_INPUT_TYPE_TIME, editor);
return;
} else if (editor.inputMethodHints == "week") {
- ewkViewInputPickerRequest(m_viewImpl->view(), EWK_INPUT_TYPE_WEEK, editor.surroundingText);
+ showInputPicker(EWK_INPUT_TYPE_WEEK, editor);
return;
}
#if ENABLE(TIZEN_DATALIST_ELEMENT)
Vector<String> optionList = m_viewImpl->page()->getFocusedInputElementDataList();
if (optionList.size() > 0) {
+ if (editor.selectionIsRange || !evas_object_focus_get(m_viewImpl->view()))
+ return;
+
if (editor.inputMethodHints == "tel")
ewkViewDataListShowRequest(m_viewImpl->view(), EWK_INPUT_TYPE_TELEPHONE, optionList);
else if (editor.inputMethodHints == "number")
{
m_contextList.clear();
}
+
+#if ENABLE(TIZEN_INPUT_TAG_EXTENSION)
+void InputMethodContextEfl::showInputPicker(Ewk_Input_Type type, const EditorState& editorState)
+{
+ if (editorState.selectionIsRange || !evas_object_focus_get(m_viewImpl->view()))
+ return;
+
+ ewkViewInputPickerRequest(m_viewImpl->view(), type, editorState.surroundingText);
+}
+#endif
+
#endif
}