XISetMask (m, XI_Motion);
XISetMask (m, XI_Enter);
XISetMask (m, XI_Leave);
+ XISetMask (m, XI_FocusIn);
+ XISetMask (m, XI_FocusOut);
XISetMask (m, XI_KeyPress);
XISetMask (m, XI_KeyRelease);
XISelectEvents (FRAME_X_DISPLAY (f),
#ifdef USE_X_TOOLKIT
XISetMask (m, XI_KeyPress);
XISetMask (m, XI_KeyRelease);
+ XISetMask (m, XI_FocusIn);
+ XISetMask (m, XI_FocusOut);
XISelectEvents (FRAME_X_DISPLAY (f),
FRAME_OUTER_WINDOW (f),
int focus_state
= focus_frame ? focus_frame->output_data.x->focus_state : 0;
-#ifdef USE_GTK
if (xi_event->evtype == XI_FocusIn
|| xi_event->evtype == XI_FocusOut)
x_focus_changed ((xi_event->evtype == XI_FocusIn
? FocusIn : FocusOut),
FOCUS_EXPLICIT,
dpyinfo, frame, bufp);
- else
-#endif
- if ((xi_event->evtype == XI_Enter
- || xi_event->evtype == XI_Leave)
- && (((XIEnterEvent *) xi_event)->detail
- != XINotifyInferior)
- && ((XIEnterEvent *) xi_event)->focus
- && !(focus_state & FOCUS_EXPLICIT))
+ else if ((xi_event->evtype == XI_Enter
+ || xi_event->evtype == XI_Leave)
+ && (((XIEnterEvent *) xi_event)->detail
+ != XINotifyInferior)
+ && ((XIEnterEvent *) xi_event)->focus
+ && !(focus_state & FOCUS_EXPLICIT))
x_focus_changed ((xi_event->evtype == XI_Enter
? FocusIn : FocusOut),
FOCUS_IMPLICIT,