+ XConfigureWindow(otk::OBDisplay::display, e.xconfigurerequest.window,
+ e.xconfigurerequest.value_mask, &xwc);
+ }
+ // madly compress all focus events
+ } else if (e.type == FocusIn) {
+ // any other types are not ones we're interested in
+ if (e.xfocus.detail == NotifyNonlinear) {
+ if (e.xfocus.window != focus) {
+ if (focus)
+ unfocus = focus;
+ focus = e.xfocus.window;
+ printf("FocusIn focus=%lx unfocus=%lx\n", focus, unfocus);
+ }
+ }
+ } else if (e.type == FocusOut) {
+ // any other types are not ones we're interested in
+ if (e.xfocus.detail == NotifyNonlinear) {
+ if (e.xfocus.window == focus) {
+ unfocus = focus;
+ focus = None;
+ printf("FocusIn focus=%lx unfocus=%lx\n", focus, unfocus);
+ }
+ }
+ } else {
+ // normal events
+ dispatch(e);
+ }
+ }
+
+ if (focus != _focus) {
+ _focus_e.xfocus.type = FocusIn;
+ _focus_e.xfocus.window = focus;
+ dispatch(_focus_e);
+ _focus = focus;
+ }
+ if (unfocus != None) {
+ _focus_e.xfocus.type = FocusOut;
+ _focus_e.xfocus.window = unfocus;
+ dispatch(_focus_e);