scim-immodule: use ecore_x_display_get instead of XOpenDisplay
SVN revision: 80548
This commit is contained in:
parent
717f492b1a
commit
e13743279f
|
@ -2416,10 +2416,10 @@ static void _x_send_key_event(const KeyEvent &key)
|
||||||
SCIM_DEBUG_FRONTEND(1) << __FUNCTION__ << "...\n";
|
SCIM_DEBUG_FRONTEND(1) << __FUNCTION__ << "...\n";
|
||||||
|
|
||||||
// Obtain the X11 display.
|
// Obtain the X11 display.
|
||||||
Display *display = XOpenDisplay(NULL);
|
Display *display = (Display *)ecore_x_display_get();
|
||||||
if (display == NULL)
|
if (display == NULL)
|
||||||
{
|
{
|
||||||
std::cerr << "XOpenDisplay failed\n";
|
std::cerr << "ecore_x_display_get() failed\n";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2448,8 +2448,6 @@ static void _x_send_key_event(const KeyEvent &key)
|
||||||
event = createKeyEvent(display, winFocus, winRoot, false, key.code, modifier);
|
event = createKeyEvent(display, winFocus, winRoot, false, key.code, modifier);
|
||||||
XSendEvent(event.display, event.window, True, KeyReleaseMask, (XEvent *)&event);
|
XSendEvent(event.display, event.window, True, KeyReleaseMask, (XEvent *)&event);
|
||||||
}
|
}
|
||||||
|
|
||||||
XCloseDisplay(display);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in New Issue