summaryrefslogtreecommitdiff
path: root/ism/extras
diff options
context:
space:
mode:
authorSungmin Kwak <sungmin.kwak@samsung.com>2018-03-14 17:22:49 +0900
committerSungmin Kwak <sungmin.kwak@samsung.com>2018-03-15 16:32:07 +0900
commit6934a958aa6a3810066f00d4af761cc4728dc7c5 (patch)
treed77f91a0085401fe310facba2d5a16a39aa57568 /ism/extras
parent6916d5d778af27555cc259b4b07634120a67dcb2 (diff)
downloadisf-6934a958aa6a3810066f00d4af761cc4728dc7c5.tar.gz
isf-6934a958aa6a3810066f00d4af761cc4728dc7c5.tar.bz2
isf-6934a958aa6a3810066f00d4af761cc4728dc7c5.zip
Modify 'Return' key handling regarding the keyboard mode
In Tv specific, the keyboard mode should be changed to SW by remocon 'Return' key. For the correct behavior, give the key to IME first then handle the keyboard mode. Change-Id: I3344a5d248d4a2f980b9ca571f4e0fc989dc0263
Diffstat (limited to 'ism/extras')
-rw-r--r--ism/extras/wayland_immodule/wayland_imcontext.c35
1 files changed, 16 insertions, 19 deletions
diff --git a/ism/extras/wayland_immodule/wayland_imcontext.c b/ism/extras/wayland_immodule/wayland_imcontext.c
index 0a917ef3..6a75c037 100644
--- a/ism/extras/wayland_immodule/wayland_imcontext.c
+++ b/ism/extras/wayland_immodule/wayland_imcontext.c
@@ -3141,25 +3141,6 @@ wayland_im_context_filter_event(Ecore_IMF_Context *ctx,
return EINA_FALSE;
}
- if (_TV) {
- if (strcmp (ecore_key_ev.keyname, "Return") == 0 && type == ECORE_IMF_EVENT_KEY_DOWN && key_dev_subclass == ECORE_DEVICE_SUBCLASS_REMOCON) {
- int val;
-
- if (vconf_get_bool (VCONFKEY_ISF_HW_KEYBOARD_INPUT_DETECTED, &val) == 0) {
- if (val) {
- LOGD ("Changed keyboard mode from H/W to S/W ");
- hw_keyboard_mode = EINA_FALSE;
- vconf_set_bool (VCONFKEY_ISF_HW_KEYBOARD_INPUT_DETECTED, 0);
-
- if (ecore_imf_context_input_panel_enabled_get (ctx)) {
- ecore_imf_context_input_panel_show (ctx);
- }
- return EINA_TRUE;
- }
- }
- }
- }
-
do {
if (!ecore_key_ev.timestamp && (ecore_key_ev.modifiers & MOD_Mod5_MASK)
&& key_dev_subclass == ECORE_DEVICE_SUBCLASS_VIRTUAL_KEYBOARD) {
@@ -3212,6 +3193,22 @@ wayland_im_context_filter_event(Ecore_IMF_Context *ctx,
if (type == ECORE_IMF_EVENT_KEY_DOWN) {
if (ret == EINA_FALSE) {
+ if (_TV) {
+ if (strcmp (ecore_key_ev.keyname, "Return") == 0 && key_dev_subclass == ECORE_DEVICE_SUBCLASS_REMOCON) {
+ int val;
+ if (vconf_get_bool (VCONFKEY_ISF_HW_KEYBOARD_INPUT_DETECTED, &val) == 0) {
+ if (val) {
+ LOGD ("Changed keyboard mode from H/W to S/W ");
+ hw_keyboard_mode = EINA_FALSE;
+ vconf_set_bool (VCONFKEY_ISF_HW_KEYBOARD_INPUT_DETECTED, 0);
+ if (ecore_imf_context_input_panel_enabled_get (ctx)) {
+ ecore_imf_context_input_panel_show (ctx);
+ }
+ return EINA_TRUE;
+ }
+ }
+ }
+ }
if (strcmp (ecore_key_ev.key, "space") == 0 ||
strcmp (ecore_key_ev.key, "KP_Space") == 0) {
autoperiod_insert (ctx);