summaryrefslogtreecommitdiff
path: root/xwayland/window-manager.c
diff options
context:
space:
mode:
authorJasper St. Pierre <jstpierre@mecheye.net>2014-08-27 09:38:33 -0400
committerPekka Paalanen <pekka.paalanen@collabora.co.uk>2014-08-27 17:21:01 +0300
commit8ffd38bedbf2790080d7bfe43445198d59ccaf72 (patch)
treece3fdfa59b667fc540524c9405b19aef4dc104ad /xwayland/window-manager.c
parent4263119d0273dd747732d4357a91fe2852fd53f3 (diff)
downloadweston-8ffd38bedbf2790080d7bfe43445198d59ccaf72.tar.gz
weston-8ffd38bedbf2790080d7bfe43445198d59ccaf72.tar.bz2
weston-8ffd38bedbf2790080d7bfe43445198d59ccaf72.zip
wm: Don't subtract the margins from the configured size
When we moved the configure event size to being based on the window geometry, we changed the coordinates of the configure request to being frame geometry based. Frame geometry includes titlebar and border, but not shadow margins. Tested-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Diffstat (limited to 'xwayland/window-manager.c')
-rw-r--r--xwayland/window-manager.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/xwayland/window-manager.c b/xwayland/window-manager.c
index f1523f5a..a216b764 100644
--- a/xwayland/window-manager.c
+++ b/xwayland/window-manager.c
@@ -2188,15 +2188,12 @@ send_configure(struct weston_surface *surface, int32_t width, int32_t height)
struct theme *t = window->wm->theme;
int vborder, hborder;
- if (window->fullscreen) {
+ if (window->decorate) {
+ hborder = 2 * t->width;
+ vborder = t->titlebar_height + t->width;
+ } else {
hborder = 0;
vborder = 0;
- } else if (window->decorate) {
- hborder = 2 * (t->margin + t->width);
- vborder = 2 * t->margin + t->titlebar_height + t->width;
- } else {
- hborder = 2 * t->margin;
- vborder = 2 * t->margin;
}
if (width > hborder)