build: use only BUILD_ECORE_IMF_XIM as a define

Summary:
meson and autotools were a bit out of sync with this, resulting in
unexpected behavior

Reviewers: billiob

Reviewed By: billiob

Subscribers: billiob, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8641
This commit is contained in:
Mike Blumenkrantz 2019-04-17 15:45:35 -04:00
parent f81dfbfe64
commit 59526ba58d
5 changed files with 5 additions and 8 deletions

View File

@ -4479,7 +4479,7 @@ if test "x${want_xim}" = "xyes" && test "x${want_ecore_imf_xim}" = "xyes" ; then
[X11 XOpenIM], [X11 XOpenIM],
[ [
have_ecore_imf_xim=yes have_ecore_imf_xim=yes
AC_DEFINE([ENABLE_XIM], [1], [Enable X Input Method]) AC_DEFINE([BUILD_ECORE_IMF_XIM], [1], [Enable X Input Method])
]) ])
fi fi

View File

@ -97,7 +97,7 @@ ecore_imf_module_init(void)
if ((!env) && (getenv("WAYLAND_DISPLAY")) && (!getenv("DISPLAY"))) if ((!env) && (getenv("WAYLAND_DISPLAY")) && (!getenv("DISPLAY")))
env = "wayland"; env = "wayland";
#endif #endif
#ifdef ENABLE_XIM #ifdef BUILD_ECORE_IMF_XIM
if ((!env) && (!getenv("WAYLAND_DISPLAY")) && (getenv("DISPLAY"))) if ((!env) && (!getenv("WAYLAND_DISPLAY")) && (getenv("DISPLAY")))
env = "xim"; env = "xim";
#endif #endif

View File

@ -1223,12 +1223,12 @@ _ecore_x_fd_handler(void *data,
XEvent ev; XEvent ev;
XNextEvent(d, &ev); XNextEvent(d, &ev);
#ifdef ENABLE_XIM #ifdef BUILD_ECORE_IMF_XIM
/* Filter event for XIM */ /* Filter event for XIM */
if (XFilterEvent(&ev, ev.xkey.window)) if (XFilterEvent(&ev, ev.xkey.window))
continue; continue;
#endif /* ifdef ENABLE_XIM */ #endif /* ifdef BUILD_ECORE_IMF_XIM */
if ((ev.type >= 0) && (ev.type < _ecore_x_event_handlers_num)) if ((ev.type >= 0) && (ev.type < _ecore_x_event_handlers_num))
{ {
if (_ecore_x_event_handlers[AnyXEvent]) if (_ecore_x_event_handlers[AnyXEvent])

View File

@ -15,9 +15,6 @@ foreach mod_name : mods
mod_src = [] mod_src = []
mod_deps = [] mod_deps = []
if loader_disabler.contains('xim') == false
config_h.set('ENABLE_'+mod_name.to_upper(), '1')
endif
if loader_disabler.contains(mod_name) == false if loader_disabler.contains(mod_name) == false
mod_install_dir = join_paths(dir_package_modules, mod_name, version_name) mod_install_dir = join_paths(dir_package_modules, mod_name, version_name)
subdir(mod_name) subdir(mod_name)

View File

@ -14,7 +14,7 @@ EFL_START_TEST(ecore_test_ecore_imf_init)
EFL_END_TEST EFL_END_TEST
static const char *built_modules[] = { static const char *built_modules[] = {
#ifdef ENABLE_XIM #ifdef BUILD_ECORE_IMF_XIM
"xim", "xim",
#endif #endif
#ifdef BUILD_ECORE_IMF_IBUS #ifdef BUILD_ECORE_IMF_IBUS