diff options
author | Jihoon Kim <jihoon48.kim@samsung.com> | 2015-05-28 13:13:25 +0900 |
---|---|---|
committer | Jihoon Kim <jihoon48.kim@samsung.com> | 2015-05-28 13:15:08 +0900 |
commit | d103f235c3daaaefcbd11ba47614cdad1954d3e8 (patch) | |
tree | b39b830196b97d901f542815898e5382547f8c10 | |
parent | 4237a7d2e0293700e1014ea58c1dc454ccffad9a (diff) | |
download | efl-d103f235c3daaaefcbd11ba47614cdad1954d3e8.tar.gz |
ecore_imf/wayland: support input language mode in wayland text input
@feature
Change-Id: I6bb0094db098060faa04458c75a23bad18093c31
-rw-r--r-- | src/modules/ecore_imf/wayland/wayland_imcontext.c | 12 | ||||
-rw-r--r-- | src/modules/ecore_imf/wayland/wayland_imcontext.h | 3 | ||||
-rw-r--r-- | src/modules/ecore_imf/wayland/wayland_module.c | 2 |
3 files changed, 16 insertions, 1 deletions
diff --git a/src/modules/ecore_imf/wayland/wayland_imcontext.c b/src/modules/ecore_imf/wayland/wayland_imcontext.c index bc40dfd312..e3d195cac0 100644 --- a/src/modules/ecore_imf/wayland/wayland_imcontext.c +++ b/src/modules/ecore_imf/wayland/wayland_imcontext.c @@ -907,6 +907,18 @@ wayland_im_context_input_hint_set(Ecore_IMF_Context *ctx, imcontext->content_hint &= ~WL_TEXT_INPUT_CONTENT_HINT_SENSITIVE_DATA; } +EAPI void +wayland_im_context_input_panel_language_set(Ecore_IMF_Context *ctx, + Ecore_IMF_Input_Panel_Lang lang) +{ + WaylandIMContext *imcontext = (WaylandIMContext *)ecore_imf_context_data_get(ctx); + + if (lang == ECORE_IMF_INPUT_PANEL_LANG_ALPHABET) + imcontext->content_hint |= WL_TEXT_INPUT_CONTENT_HINT_LATIN; + else + imcontext->content_hint &= ~WL_TEXT_INPUT_CONTENT_HINT_LATIN; +} + WaylandIMContext *wayland_im_context_new (struct wl_text_input_manager *text_input_manager) { WaylandIMContext *context = calloc(1, sizeof(WaylandIMContext)); diff --git a/src/modules/ecore_imf/wayland/wayland_imcontext.h b/src/modules/ecore_imf/wayland/wayland_imcontext.h index 3b004eec77..a105c78a96 100644 --- a/src/modules/ecore_imf/wayland/wayland_imcontext.h +++ b/src/modules/ecore_imf/wayland/wayland_imcontext.h @@ -72,6 +72,9 @@ EAPI void wayland_im_context_input_mode_set(Ecore_IMF_Context *ctx, EAPI void wayland_im_context_input_hint_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Hints input_hints); +EAPI void wayland_im_context_input_panel_language_set(Ecore_IMF_Context *ctx, + Ecore_IMF_Input_Panel_Lang lang); + WaylandIMContext *wayland_im_context_new (struct wl_text_input_manager *text_input_manager); extern int _ecore_imf_wayland_log_dom; diff --git a/src/modules/ecore_imf/wayland/wayland_module.c b/src/modules/ecore_imf/wayland/wayland_module.c index ed343bdd9d..1d53b87b94 100644 --- a/src/modules/ecore_imf/wayland/wayland_module.c +++ b/src/modules/ecore_imf/wayland/wayland_module.c @@ -66,7 +66,7 @@ static Ecore_IMF_Context_Class wayland_imf_class = NULL, /* control panel hide */ wayland_im_context_input_panel_layout_set, /* input_panel_layout_set */ NULL, /* input_panel_layout_get, */ - NULL, /* input_panel_language_set, */ + wayland_im_context_input_panel_language_set,/* input_panel_language_set, */ NULL, /* input_panel_language_get, */ wayland_im_context_cursor_location_set, /* cursor_location_set */ NULL, /* input_panel_imdata_set */ |