Hi Riccardo,
On Wed, May 09, 2007 at 05:29:08PM +0200, Riccardo Murri wrote:
> - the "place" patch adds a `place()` function that can be used to
> instantly move a floating window to a "cardinal point" of the
> window area.
>
> There's a bug with this: the moved window will at times loose
> focus. I could not identify the culprit, as the bug seems to
> manifest itself at random... Any clue will be appreciated :-)
> +static void
> +_place(const vertical_placement_t vpos, const horizontal_placement_t hpos)
> +{
> + unsigned int nx, ny;
> +
> + if(NULL == sel || !sel->isfloating)
> + return;
> +
> + /* FIXME: should we take window gravity into account here? */
> + nx = wax + hpos*(waw - sel->w)/2;
> + ny = way + vpos*(wah - sel->h)/2;
> +
> + XMoveWindow(dpy, sel->win, nx, ny);
XSync(dpy, False);
while(XCheckMaskEvent(dpy, EnterWindowMask, &ev));
> +}
If you'll add those two lines to your patch, I believe the bug
you describe might be fixed.
Regards,
-- Anselm R. Garbe >< http://www.suckless.org/ >< GPG key: 0D73F361Received on Thu May 10 2007 - 13:51:58 UTC
This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 14:41:12 UTC