diff options
author | markt <markt> | 2007-02-10 18:13:30 (GMT) |
---|---|---|
committer | markt <markt> | 2007-02-10 18:13:30 (GMT) |
commit | 6b92622d6e7431fc7891a56c9bea89bc80f8e91e (patch) | |
tree | 108ed7746b9e0197eae6fb37dbfd9b5184d53775 | |
parent | 6fdda1a31d2417c23f5f222114d30ce6abec8b40 (diff) | |
download | fluxbox-6b92622d6e7431fc7891a56c9bea89bc80f8e91e.zip fluxbox-6b92622d6e7431fc7891a56c9bea89bc80f8e91e.tar.bz2 |
window was growing when we received a configurerequest that changed width but not height
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | src/Window.cc | 6 |
2 files changed, 9 insertions, 1 deletions
@@ -1,5 +1,9 @@ | |||
1 | (Format: Year/Month/Day) | 1 | (Format: Year/Month/Day) |
2 | Changes for 1.0rc3: | 2 | Changes for 1.0rc3: |
3 | *07/02/10: | ||
4 | * Fixed a bug with resizing windows for clients when only the width is | ||
5 | specified (Mark) | ||
6 | Window.cc | ||
3 | *07/02/09: | 7 | *07/02/09: |
4 | * Introduced support for mouse buttons in the keys file (Mark) | 8 | * Introduced support for mouse buttons in the keys file (Mark) |
5 | - Mouse buttons are bound to new `keys' Mouse1, Mouse2, etc. | 9 | - Mouse buttons are bound to new `keys' Mouse1, Mouse2, etc. |
diff --git a/src/Window.cc b/src/Window.cc index 56b1e09..4c6c681 100644 --- a/src/Window.cc +++ b/src/Window.cc | |||
@@ -2584,14 +2584,18 @@ void FluxboxWindow::configureRequestEvent(XConfigureRequestEvent &cr) { | |||
2584 | frame().setActiveGravity(client->gravity(), client->old_bw); | 2584 | frame().setActiveGravity(client->gravity(), client->old_bw); |
2585 | } | 2585 | } |
2586 | 2586 | ||
2587 | if (cr.value_mask & CWWidth) | 2587 | if (cr.value_mask & CWWidth) { |
2588 | cw = cr.width; | 2588 | cw = cr.width; |
2589 | // we must set this now, or else window grows when height not specified | ||
2590 | ch -= (frame().titlebarHeight() + frame().handleHeight()); | ||
2591 | } | ||
2589 | 2592 | ||
2590 | if (cr.value_mask & CWHeight) | 2593 | if (cr.value_mask & CWHeight) |
2591 | ch = cr.height; | 2594 | ch = cr.height; |
2592 | 2595 | ||
2593 | // whether we should send ConfigureNotify to netizens | 2596 | // whether we should send ConfigureNotify to netizens |
2594 | // the request is for client window so we resize the frame to it first | 2597 | // the request is for client window so we resize the frame to it first |
2598 | // NOTE: this might not work correctly if client actually requests that size | ||
2595 | if (frame().width() != cw || frame().height() != ch) { | 2599 | if (frame().width() != cw || frame().height() != ch) { |
2596 | if (frame().x() != cx || frame().y() != cy) | 2600 | if (frame().x() != cx || frame().y() != cy) |
2597 | frame().moveResizeForClient(cx, cy, cw, ch); | 2601 | frame().moveResizeForClient(cx, cy, cw, ch); |