summaryrefslogtreecommitdiff
path: root/beryl-plugins/src/resize.c
diff options
context:
space:
mode:
authorguillaume <guillaume@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2007-01-28 22:07:43 +0000
committerguillaume <guillaume@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2007-01-28 22:07:43 +0000
commitb5112abb60220302eaaf8dbd47c8d47e4963e4b1 (patch)
tree56d69ba7ae7e51120e46066e140e2ea3fcc539c3 /beryl-plugins/src/resize.c
parentc6c630dd546006abdd0cc5bc070b4ae5de3dbb61 (diff)
downloadmarex-dev-b5112abb60220302eaaf8dbd47c8d47e4963e4b1.tar.gz
marex-dev-b5112abb60220302eaaf8dbd47c8d47e4963e4b1.tar.bz2
beryl-plugins: resize
- fix 0 resize - call resizeWindowPreview for scale/outline modes - whitespace change (the switch block) git-svn-id: file:///beryl/trunk@3325 d7aaf104-2d23-0410-ae22-9d23157bf5a3
Diffstat (limited to 'beryl-plugins/src/resize.c')
-rw-r--r--beryl-plugins/src/resize.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/beryl-plugins/src/resize.c b/beryl-plugins/src/resize.c
index 1e771f5..afe93e1 100644
--- a/beryl-plugins/src/resize.c
+++ b/beryl-plugins/src/resize.c
@@ -304,11 +304,15 @@ static void resizeApply(CompDisplay * d)
switch (rd->resizeMode)
{
- case ResizeModeStretch:
- move_only = 1;
- case ResizeModeNormal:
- resizeUpdateWindowRealSize(d, move_only);
+ case ResizeModeStretch:
+ move_only = 1;
+ case ResizeModeNormal:
+ resizeUpdateWindowRealSize(d, move_only);
}
+
+ if (rd->resizeMode != ResizeModeNormal)
+ resizeWindowPreview (rd->w, rd->currentX, rd->currentY,
+ rd->currentWidth, rd->currentHeight);
}
static void resizeUpdateWindowSize(CompDisplay * d, int dx, int dy)
@@ -615,7 +619,11 @@ resizeTerminate(CompDisplay * d,
configureXWindow(rd->w, CWX | CWY | CWWidth | CWHeight, &xwc);
rd->ungrabPending = TRUE;
- } else if (rd->resizeMode != ResizeModeNormal) {
+ } else if (rd->resizeMode != ResizeModeNormal
+ && (rd->currentX != rd->w->serverX
+ || rd->currentY != rd->w->serverY
+ || rd->currentWidth != rd->w->serverWidth
+ || rd->currentHeight != rd->w->serverHeight)) {
rd->ungrabPending = TRUE;
resizeUpdateWindowRealSize(d, 0);
} else {