rem: if (openedSwitchMenu) OpenSwitchMenu(scr, scr->scr_width/2, scr->scr_height/2, False);
add: if (openedSwitchMenu) {  WMPoint center = wGetPointToCenterRectInHead(scr, wGetHeadForPointerLocation(scr), 0, 0); OpenSwitchMenu(scr, center.x, center.y, False); }
context: StartWindozeCycle(WWindow *wwin, XEvent *event, Bool next){    WScreen *scr = wScreenForRootWindow(event->xkey.root);    Bool done = False;    Bool openedSwitchMenu = False;    WWindow *newFocused;    WWindow *oldFocused;    int modifiers;    XModifierKeymap *keymap = NULL;    Bool hasModifier;    Bool somethingElse = False;    XEvent ev;    if (!wwin)	return;        if (next)	hasModifier = (wKeyBindings[WKBD_FOCUSNEXT].modifier != 0);    else	hasModifier = (wKeyBindings[WKBD_FOCUSPREV].modifier != 0);    if (hasModifier) {	keymap = XGetModifierMapping(dpy);    	XGrabKeyboard(dpy, scr->root_win, False, GrabModeAsync, GrabModeAsync, 		      CurrentTime);    }    if (next) {	if (wPreferences.windows_cycling)	    newFocused = nextToFocusAfter(wwin);	else	    newFocused = nextFocusWindow(wwin);    } else {	if (wPreferences.windows_cycling)	    newFocused = nextToFocusBefore(wwin);	else	    newFocused = prevFocusWindow(wwin);    }    scr->flags.doing_alt_tab = 1;    if (wPreferences.circ_raise)	XRaiseWindow(dpy, newFocused->frame->core->window);    wWindowFocus(newFocused, scr->focused_window);    oldFocused = newFocused;    if (hasModifier)	done = False;    else	done = True;    #if 0    if (wPreferences.popup_switchmenu && 	(!scr->switch_menu || !scr->switch_menu->flags.mapped)) {	OpenSwitchMenu(scr, scr->scr_width/2, scr->scr_height/2, False);	openedSwitchMenu = True;    }#endif    while (!done) {	WMMaskEvent(dpy,KeyPressMask|KeyReleaseMask|ExposureMask, &ev);	if (ev.type != KeyRelease && ev.type != KeyPress) {	    WMHandleEvent(&ev);	    continue;	}	/* ignore CapsLock */	modifiers = ev.xkey.state & ValidModMask;	if (ev.type == KeyPress) {	    if (wKeyBindings[WKBD_FOCUSNEXT].keycode == ev.xkey.keycode		&& wKeyBindings[WKBD_FOCUSNEXT].modifier == modifiers) {		newFocused = nextToFocusAfter(newFocused);		wWindowFocus(newFocused, oldFocused);		oldFocused = newFocused;	    		if (wPreferences.circ_raise) {		    /* restore order */		    CommitStacking(scr);		    XRaiseWindow(dpy, newFocused->frame->core->window);		}	    } else if (wKeyBindings[WKBD_FOCUSPREV].keycode == ev.xkey.keycode		       && wKeyBindings[WKBD_FOCUSPREV].modifier == modifiers) {		newFocused = nextToFocusBefore(newFocused);		wWindowFocus(newFocused, oldFocused);		oldFocused = newFocused;		if (wPreferences.circ_raise) {		    /* restore order */		    CommitStacking(scr);		    XRaiseWindow(dpy, newFocused->frame->core->window);		}	    } else {		somethingElse = True;		done = True;	    }	} else if (ev.type == KeyRelease) {	    int i;	    for (i = 0; i < 8 * keymap->max_keypermod; i++) {		if (keymap->modifiermap[i] == ev.xkey.keycode &&		    wKeyBindings[WKBD_FOCUSNEXT].modifier 		    & 1<<(i/keymap->max_keypermod)) {		    done = True;		    break;		}	    }	}    }    if (keymap)	XFreeModifiermap(keymap);    if (hasModifier) {	XUngrabKeyboard(dpy, CurrentTime);    }    wSetFocusTo(scr, newFocused);    if (wPreferences.circ_raise) {	wRaiseFrame(newFocused->frame->core);    	CommitStacking(scr);    }    scr->flags.doing_alt_tab = 0;    if (openedSwitchMenu) 	OpenSwitchMenu(scr, scr->scr_width/2, scr->scr_height/2, False);        if (somethingElse) {	WMHandleEvent(&ev);    }}