diff options
author | Ira Rice <irarice@gmail.com> | 2009-03-10 08:43:26 -0600 |
---|---|---|
committer | Ira Rice <irarice@gmail.com> | 2009-03-10 08:43:26 -0600 |
commit | 1570fb33d5909786ef2997246ada7c46dd6de9e4 (patch) | |
tree | 0f0f70097de966fbec38a6062afa592e10bd2912 /src/gui/window.cpp | |
parent | 6b0659b6cc921aa6589681820b431af44f458440 (diff) | |
download | mana-1570fb33d5909786ef2997246ada7c46dd6de9e4.tar.gz mana-1570fb33d5909786ef2997246ada7c46dd6de9e4.tar.bz2 mana-1570fb33d5909786ef2997246ada7c46dd6de9e4.tar.xz mana-1570fb33d5909786ef2997246ada7c46dd6de9e4.zip |
Reverted last commit (since I confused it with something else) as well
as removed a redundant call for sizing in the minimap class.
Signed-off-by: Ira Rice <irarice@gmail.com>
Diffstat (limited to 'src/gui/window.cpp')
-rw-r--r-- | src/gui/window.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/gui/window.cpp b/src/gui/window.cpp index 3c73a586..5253dd2e 100644 --- a/src/gui/window.cpp +++ b/src/gui/window.cpp @@ -196,9 +196,13 @@ void Window::setContentSize(int width, int height) width = width + 2 * getPadding(); height = height + getPadding() + getTitleBarHeight(); - if (getMaxWidth() < width) + if (getMinWidth() > width) + width = getMinWidth(); + else if (getMaxWidth() < width) width = getMaxWidth(); - if (getMaxHeight() < height) + if (getMinHeight() > height) + height = getMinHeight(); + else if (getMaxHeight() < height) height = getMaxHeight(); setSize(width, height); |