From: Robin Dunn Date: Wed, 16 Jun 2004 02:15:27 +0000 (+0000) Subject: Add SetMinSize and SetMaxSize to go along with the Get's already there. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/49f1dc5e8a15653df6e4ca8144e4c22a9fb5e168?ds=inline Add SetMinSize and SetMaxSize to go along with the Get's already there. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27818 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/window.h b/include/wx/window.h index 8b53af60c0..87dc4cc691 100644 --- a/include/wx/window.h +++ b/include/wx/window.h @@ -366,6 +366,9 @@ public: virtual wxSize GetMaxSize() const { return wxSize( m_maxWidth, m_maxHeight ); } virtual wxSize GetMinSize() const { return wxSize( m_minWidth, m_minHeight ); } + void SetMinSize(const wxSize& minSize) { SetSizeHints(minSize); } + void SetMaxSize(const wxSize& maxSize) { SetSizeHints(GetMinSize(), maxSize); } + // Methods for accessing the virtual size of a window. For most // windows this is just the client area of the window, but for // some like scrolled windows it is more or less independent of