fix _NET_MOVERESIZE_WINDOW resize issue (#1108)
handing over the dimensions of a WinClient client must not contain properties of the FbWinFrame, otherwise they get added twice in FbWinFrame::moveResizeForClient() and thus result in a resizes when no resize is wanted. other changes: it's easier for me to detect the nth bit when the value looks like (1 << 8) instead of 0x0100 (for the 8th bit). that is why i changed 0x0100, 0x0200 etc. in the nearby code.
This commit is contained in:
parent
f3e82cae83
commit
5f45524211
1 changed files with 6 additions and 6 deletions
12
src/Ewmh.cc
12
src/Ewmh.cc
|
@ -1177,14 +1177,14 @@ bool Ewmh::checkClientMessage(const XClientMessageEvent &ce,
|
||||||
if (winclient == 0 || winclient->fbwindow() == 0)
|
if (winclient == 0 || winclient->fbwindow() == 0)
|
||||||
return true;
|
return true;
|
||||||
// ce.data.l[0] = gravity and flags
|
// ce.data.l[0] = gravity and flags
|
||||||
int x = (ce.data.l[0] & 0x0100) ? ce.data.l[1] :
|
int x = (ce.data.l[0] & (1 << 8)) ? ce.data.l[1] :
|
||||||
winclient->fbwindow()->x();
|
winclient->fbwindow()->x();
|
||||||
int y = (ce.data.l[0] & 0x0200) ? ce.data.l[2] :
|
int y = (ce.data.l[0] & (1 << 9)) ? ce.data.l[2] :
|
||||||
winclient->fbwindow()->y();
|
winclient->fbwindow()->y();
|
||||||
unsigned int width = (ce.data.l[0] & 0x0400) ? ce.data.l[3] :
|
unsigned int width = (ce.data.l[0] & (1 << 10)) ? ce.data.l[3] :
|
||||||
winclient->fbwindow()->width();
|
winclient->width();
|
||||||
unsigned int height = (ce.data.l[0] & 0x0800) ? ce.data.l[4] :
|
unsigned int height = (ce.data.l[0] & (1 << 11)) ? ce.data.l[4] :
|
||||||
winclient->fbwindow()->height();
|
winclient->height();
|
||||||
int win_gravity=ce.data.l[0] & 0xFF;
|
int win_gravity=ce.data.l[0] & 0xFF;
|
||||||
winclient->fbwindow()->moveResizeForClient(x, y, width, height,
|
winclient->fbwindow()->moveResizeForClient(x, y, width, height,
|
||||||
win_gravity, winclient->old_bw);
|
win_gravity, winclient->old_bw);
|
||||||
|
|
Loading…
Reference in a new issue