From 819ed3a1d7df6fe33ce6b06516eb895a2e7b0d9b Mon Sep 17 00:00:00 2001 From: raster Date: Tue, 26 Jul 2011 12:04:27 +0000 Subject: [PATCH] From: Jihoon Kim Subject: Re: [E-devel] [Patch] Add XIM module for ecore_imf Patch to set the right window ID for IMF access from Edje git-svn-id: http://svn.enlightenment.org/svn/e/trunk/edje@61756 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- configure.ac | 3 ++- src/lib/edje_entry.c | 3 ++- src/lib/edje_private.h | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index e897f07..21fd8c7 100644 --- a/configure.ac +++ b/configure.ac @@ -266,6 +266,7 @@ PKG_CHECK_MODULES([EDJE], eet >= 1.4.0 evas >= 1.0.999 ecore >= 1.0.0 + ecore-evas >= 1.0.0 ecore-file >= 1.0.0 embryo >= 1.0.0 ]) @@ -273,7 +274,7 @@ PKG_CHECK_MODULES([EDJE], EDJE_LIBS="${EDJE_LIBS} ${LUA_LIBS} ${lua_libs}" EDJE_CFLAGS="${EDJE_CFLAGS} ${LUA_CFLAGS}" -requirement_edje="embryo >= 1.0.0 ecore >= 1.0.0 evas >= 1.0.0 eet >= 1.4.0 eina >= 1.0.0 ${requirement_edje}" +requirement_edje="embryo >= 1.0.0 ecore-evas >= 1.0.0 ecore >= 1.0.0 evas >= 1.0.0 eet >= 1.4.0 eina >= 1.0.0 ${requirement_edje}" requirement_edje="${requirement_lua} ${requirement_edje}" have_ecore_imf="no" diff --git a/src/lib/edje_entry.c b/src/lib/edje_entry.c index 0d10cf6..0837366 100644 --- a/src/lib/edje_entry.c +++ b/src/lib/edje_entry.c @@ -1960,7 +1960,7 @@ _edje_entry_real_part_init(Edje_Real_Part *rp) if (!en->imf_context) goto done; - ecore_imf_context_client_window_set(en->imf_context, rp->object); + ecore_imf_context_client_window_set(en->imf_context, ecore_evas_window_get(ecore_evas_ecore_evas_get(rp->edje->base.evas))); ecore_imf_context_client_canvas_set(en->imf_context, rp->edje->base.evas); ecore_imf_context_retrieve_surrounding_callback_set(en->imf_context, @@ -2897,6 +2897,7 @@ _edje_entry_imf_event_preedit_changed_cb(void *data, int type __UNUSED__, void * if (en->imf_context != ev->ctx) return ECORE_CALLBACK_PASS_ON; ecore_imf_context_preedit_string_get(en->imf_context, &preedit_string, &cursor_pos); + if (!preedit_string) return ECORE_CALLBACK_PASS_ON; if (!strcmp(preedit_string, "")) preedit_end_state = EINA_TRUE; diff --git a/src/lib/edje_private.h b/src/lib/edje_private.h index 4bd65ad..985c82f 100644 --- a/src/lib/edje_private.h +++ b/src/lib/edje_private.h @@ -52,6 +52,7 @@ void *alloca (size_t); #include #include #include +#include #include #ifdef HAVE_ECORE_IMF # include -- 2.7.4