X11 platform: Fl::enable_im() crashes without input methods (#1364)
This commit is contained in:
parent
7fb11e66ee
commit
ab5b28acf2
@ -388,7 +388,7 @@ void Fl_X11_Screen_Driver::new_ic()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
XFree(xim_styles);
|
if (xim_styles) XFree(xim_styles);
|
||||||
|
|
||||||
if (sarea) {
|
if (sarea) {
|
||||||
xim_ic = XCreateIC(xim_im,
|
xim_ic = XCreateIC(xim_im,
|
||||||
@ -521,7 +521,7 @@ void Fl_X11_Screen_Driver::enable_im() {
|
|||||||
if (win && win->shown()) {
|
if (win && win->shown()) {
|
||||||
xim_activate(fl_xid(win));
|
xim_activate(fl_xid(win));
|
||||||
XSetICFocus(xim_ic);
|
XSetICFocus(xim_ic);
|
||||||
} else {
|
} else if (xim_im) {
|
||||||
new_ic();
|
new_ic();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user