summaryrefslogtreecommitdiff
path: root/src/lib/ecore_imf/ecore_imf_context.c
diff options
context:
space:
mode:
authorJihoon Kim <jihoon48.kim@samsung.com>2014-08-30 12:45:38 +0900
committerJihoon Kim <jihoon48.kim@samsung.com>2014-08-30 12:45:44 +0900
commit44326f9ed8030647fca283e0f7fc00443f12102d (patch)
tree1c16b685c0386e5ef31355503790de0cb1ecf7b9 /src/lib/ecore_imf/ecore_imf_context.c
parent39cb5207186665959cf6101854e9e973dafb93f4 (diff)
ecore_imf: Add ecore_imf_context_input_hint_set API
Diffstat (limited to 'src/lib/ecore_imf/ecore_imf_context.c')
-rw-r--r--src/lib/ecore_imf/ecore_imf_context.c35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/lib/ecore_imf/ecore_imf_context.c b/src/lib/ecore_imf/ecore_imf_context.c
index 65154bc78d..b301f3457e 100644
--- a/src/lib/ecore_imf/ecore_imf_context.c
+++ b/src/lib/ecore_imf/ecore_imf_context.c
@@ -153,6 +153,9 @@ ecore_imf_context_add(const char *id)
153 * set on the immodule */ 153 * set on the immodule */
154 ecore_imf_context_autocapital_type_set(ctx, ECORE_IMF_AUTOCAPITAL_TYPE_SENTENCE); 154 ecore_imf_context_autocapital_type_set(ctx, ECORE_IMF_AUTOCAPITAL_TYPE_SENTENCE);
155 155
156 /* default input hint */
157 ecore_imf_context_input_hint_set(ctx, ECORE_IMF_INPUT_HINT_AUTO_COMPLETE);
158
156 /* default input panel enabled status is EINA_TRUE, so let's make sure it's 159 /* default input panel enabled status is EINA_TRUE, so let's make sure it's
157 * set on the immodule */ 160 * set on the immodule */
158 ecore_imf_context_input_panel_enabled_set(ctx, EINA_TRUE); 161 ecore_imf_context_input_panel_enabled_set(ctx, EINA_TRUE);
@@ -830,6 +833,38 @@ ecore_imf_context_control_panel_hide(Ecore_IMF_Context *ctx)
830} 833}
831 834
832EAPI void 835EAPI void
836ecore_imf_context_input_hint_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Hints input_hints)
837{
838 if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT))
839 {
840 ECORE_MAGIC_FAIL(ctx, ECORE_MAGIC_CONTEXT,
841 "ecore_imf_context_input_hint_set");
842 return;
843 }
844
845 if (ctx->input_hints != input_hints)
846 {
847 if (ctx->klass->input_hint_set)
848 ctx->klass->input_hint_set(ctx, input_hints);
849
850 ctx->input_hints = input_hints;
851 }
852}
853
854EAPI Ecore_IMF_Input_Hints
855ecore_imf_context_input_hint_get(Ecore_IMF_Context *ctx)
856{
857 if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT))
858 {
859 ECORE_MAGIC_FAIL(ctx, ECORE_MAGIC_CONTEXT,
860 "ecore_imf_context_input_hint_get");
861 return ECORE_IMF_INPUT_HINT_NONE;
862 }
863
864 return ctx->input_hints;
865}
866
867EAPI void
833ecore_imf_context_input_panel_show(Ecore_IMF_Context *ctx) 868ecore_imf_context_input_panel_show(Ecore_IMF_Context *ctx)
834{ 869{
835 if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT)) 870 if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT))