From 6d09c8f4667f75fece4a5549de237e17490398cf Mon Sep 17 00:00:00 2001 From: Bjørn Lindeijer Date: Sun, 15 Apr 2007 19:19:01 +0000 Subject: Increased minimum window height and fixed a problem with setting window content size which was introduced with the new resize grip. --- ChangeLog | 3 +++ src/gui/window.cpp | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 348e90fd..92b37960 100644 --- a/ChangeLog +++ b/ChangeLog @@ -8,6 +8,9 @@ windows using their borders (except for the top one, since that's the title bar for Guichan) and the resize grip in the bottom right is much easier to grab. + * src/gui/window.cpp: Increased minimum window height and fixed a + problem with setting window content size which was introduced with the + new resize grip. 2007-04-05 Eugenio Favalli diff --git a/src/gui/window.cpp b/src/gui/window.cpp index bd3e7eb5..6165ce70 100644 --- a/src/gui/window.cpp +++ b/src/gui/window.cpp @@ -65,7 +65,7 @@ Window::Window(const std::string& caption, bool modal, Window *parent): mMouseResize(0), mSticky(false), mMinWinWidth(100), - mMinWinHeight(28), + mMinWinHeight(40), mMaxWinWidth(INT_MAX), mMaxWinHeight(INT_MAX) { @@ -182,13 +182,13 @@ void Window::draw(gcn::Graphics *graphics) void Window::setContentWidth(int width) { mChrome->setWidth(width); - resizeToContent(); + setWidth(width + 2 * getPadding()); } void Window::setContentHeight(int height) { mChrome->setHeight(height); - resizeToContent(); + setHeight(height + getPadding() + getTitleBarHeight()); } void Window::setContentSize(int width, int height) -- cgit v1.2.3-70-g09d2