diff options
author | George Hazan <ghazan@miranda.im> | 2019-05-13 14:54:10 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-05-13 14:54:10 +0300 |
commit | 7a20312b1ea4998111a05f207be8023a499050fb (patch) | |
tree | 7551d409fd942d2a0c924897b1c0770d68f8950d /include | |
parent | 0dd998f1a2d1ca3a3fca9bc6ea85c40ccfeae850 (diff) |
CDlgBase::SetMinSize - a way to get rid of WM_GETMINMAXINFO in DlgProc
Diffstat (limited to 'include')
-rw-r--r-- | include/m_gui.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/m_gui.h b/include/m_gui.h index 4fa9f8c667..d611778a74 100644 --- a/include/m_gui.h +++ b/include/m_gui.h @@ -402,6 +402,7 @@ public: __forceinline HWND GetHwnd() const { return m_hwnd; }
__forceinline void Hide() { Show(SW_HIDE); }
__forceinline bool IsInitialized() const { return m_initialized; }
+ __forceinline void SetMinSize(int x, int y) { m_iMinWidth = x, m_iMinHeight = y; }
__forceinline void SetParent(HWND hwnd) { m_hwndParent = hwnd; }
__forceinline CCtrlBase* operator[](int iControlId) { return FindControl(iControlId); }
@@ -466,6 +467,7 @@ private: bool VerifyControls(bool (CCtrlBase::*fn)());
CTimer* FindTimer(int idEvent);
+ int m_iMinWidth = -1, m_iMinHeight = -1;
static BOOL CALLBACK GlobalFieldEnum(HWND hwnd, LPARAM lParam);
static INT_PTR CALLBACK GlobalDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
|