mirror of
https://github.com/fltk/fltk.git
synced 2026-05-31 22:04:26 +08:00
Remove commented out, alternative IM code.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10313 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
+8
-35
@@ -1279,42 +1279,15 @@ int fl_handle(const XEvent& thisevent)
|
|||||||
|
|
||||||
if (fl_xim_ic && (xevent.type == FocusIn))
|
if (fl_xim_ic && (xevent.type == FocusIn))
|
||||||
{
|
{
|
||||||
#define POOR_XIM
|
if (xim_win != xid) {
|
||||||
#ifdef POOR_XIM
|
xim_win = xid;
|
||||||
if (xim_win != xid)
|
XDestroyIC(fl_xim_ic);
|
||||||
{
|
fl_xim_ic = NULL;
|
||||||
xim_win = xid;
|
fl_new_ic();
|
||||||
XDestroyIC(fl_xim_ic);
|
XSetICValues(fl_xim_ic, XNFocusWindow, xevent.xclient.window,
|
||||||
fl_xim_ic = NULL;
|
XNClientWindow, xid, NULL);
|
||||||
fl_new_ic();
|
|
||||||
XSetICValues(fl_xim_ic,
|
|
||||||
XNFocusWindow, xevent.xclient.window,
|
|
||||||
XNClientWindow, xid,
|
|
||||||
NULL);
|
|
||||||
}
|
|
||||||
fl_set_spot(spotf, spots, spot.x, spot.y, spot.width, spot.height);
|
|
||||||
#else
|
|
||||||
if (Fl::first_window() && Fl::first_window()->modal()) {
|
|
||||||
Window x = fl_xid(Fl::first_window());
|
|
||||||
if (x != xim_win) {
|
|
||||||
xim_win = x;
|
|
||||||
XSetICValues(fl_xim_ic,
|
|
||||||
XNFocusWindow, xim_win,
|
|
||||||
XNClientWindow, xim_win,
|
|
||||||
NULL);
|
|
||||||
fl_set_spot(spotf, spots, spot.x, spot.y, spot.width, spot.height);
|
|
||||||
}
|
|
||||||
} else if (xim_win != xid && xid) {
|
|
||||||
xim_win = xid;
|
|
||||||
XSetICValues(fl_xim_ic,
|
|
||||||
XNFocusWindow, xevent.xclient.window,
|
|
||||||
XNClientWindow, xid,
|
|
||||||
//XNFocusWindow, xim_win,
|
|
||||||
//XNClientWindow, xim_win,
|
|
||||||
NULL);
|
|
||||||
fl_set_spot(spotf, spots, spot.x, spot.y, spot.width, spot.height);
|
|
||||||
}
|
}
|
||||||
#endif
|
fl_set_spot(spotf, spots, spot.x, spot.y, spot.width, spot.height);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( XFilterEvent((XEvent *)&xevent, 0) )
|
if ( XFilterEvent((XEvent *)&xevent, 0) )
|
||||||
|
|||||||
Reference in New Issue
Block a user