diff --git a/src/desktops.c b/src/desktops.c index 625fd5c1..c93c8b43 100644 --- a/src/desktops.c +++ b/src/desktops.c @@ -1054,7 +1054,7 @@ DeskGotoNum(unsigned int desk) DeskGoto(dsk); } -void +static void DeskSwitchStart(void) { FocusNewDeskBegin(); @@ -1065,7 +1065,7 @@ DeskSwitchStart(void) DesksEventsConfigure(0); } -void +static void DeskSwitchDone(void) { /* we flipped - re-enable enter and leave events */ @@ -1139,8 +1139,8 @@ DeskGoto(Desk * dsk) DeskEnter(dsk); } - ActionsResume(); DeskSwitchDone(); + ActionsResume(); ModulesSignal(ESIGNAL_DESK_SWITCH_DONE, NULL); } @@ -1587,10 +1587,9 @@ DeskCurrentGotoArea(int ax, int ay) /* set hints up for it */ HintsSetDesktopViewport(); - ActionsResume(); - /* re-focus on a new ewin on that new desktop area */ DeskSwitchDone(); + ActionsResume(); ModulesSignal(ESIGNAL_AREA_SWITCH_DONE, DesksGetCurrent()); diff --git a/src/desktops.h b/src/desktops.h index bb816f11..c89981c8 100644 --- a/src/desktops.h +++ b/src/desktops.h @@ -71,9 +71,6 @@ void DeskCurrentMoveAreaBy(int ax, int ay); void DeskGotoByEwin(EWin * ewin); -void DeskSwitchStart(void); -void DeskSwitchDone(void); - unsigned int DesksGetNumber(void); Desk *DesksGetCurrent(void); Desk *DesktopAt(int x, int y); diff --git a/src/focus.c b/src/focus.c index d2a72d99..dcffeeac 100644 --- a/src/focus.c +++ b/src/focus.c @@ -501,7 +501,7 @@ FocusNewDesk(void) /* Set the mouse-over window */ Mode.mouse_over_ewin = GetEwinByCurrentPointer(); - FocusToEWin(NULL, FOCUS_DESK_ENTER); + doFocusToEwin(NULL, FOCUS_DESK_ENTER); } static void diff --git a/src/moveresize.c b/src/moveresize.c index 59d5077d..d2b2e951 100644 --- a/src/moveresize.c +++ b/src/moveresize.c @@ -197,8 +197,6 @@ ActionMoveSuspend(void) /* If non opaque undraw our boxes */ if (Mode_mr.mode > 0) { - EUngrabServer(); - lst = ListWinGroupMembersForEwin(ewin, GROUP_ACTION_MOVE, Mode.nogroup, &num); @@ -210,6 +208,8 @@ ActionMoveSuspend(void) } if (lst) Efree(lst); + + EUngrabServer(); } return 0; @@ -220,7 +220,7 @@ ActionMoveResume(void) { EWin *ewin, **lst; int i, num; - int x, y, ax, ay, fl; + int x, y, fl; ewin = Mode_mr.ewin; if (!ewin) @@ -236,8 +236,6 @@ ActionMoveResume(void) if (Mode_mr.mode > 0) EGrabServer(); - DeskCurrentGetArea(&ax, &ay); - /* Redraw any windows that were in "move mode" */ lst = ListWinGroupMembersForEwin(ewin, GROUP_ACTION_MOVE, Mode.nogroup, &num);