summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDana Jansens <danakj@orodu.net>2003-02-10 00:21:09 +0000
committerDana Jansens <danakj@orodu.net>2003-02-10 00:21:09 +0000
commitebdfbdabbe503ea479525c2a0148ce50f7003b55 (patch)
tree5e3ab5b680b020cb16e376da350659a008fdc55b /src
parent5673ab7e708fa0368ec8e1056a2f61ca8ba49848 (diff)
keep things in min/max bounds properly
Diffstat (limited to 'src')
-rw-r--r--src/client.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client.cc b/src/client.cc
index 25434573..6f18445d 100644
--- a/src/client.cc
+++ b/src/client.cc
@@ -1149,10 +1149,10 @@ void Client::internal_resize(Corner anchor, int w, int h,
// and aspect ratios
// smaller than min size or bigger than max size?
+ if (w > _max_size.width()) w = _max_size.width();
if (w < _min_size.width()) w = _min_size.width();
- else if (w > _max_size.width()) w = _max_size.width();
+ if (h > _max_size.height()) h = _max_size.height();
if (h < _min_size.height()) h = _min_size.height();
- else if (h > _max_size.height()) h = _max_size.height();
// adjust the height ot match the width for the aspect ratios
if (_min_ratio)