comctl32: Fix to ComboBoxEx processing of WM_ENABLE message
Richard Bradbrook
richard at bradders2000.co.uk
Sun Jul 31 12:35:48 CDT 2011
---
dlls/comctl32/comboex.c | 19 +++++++++++++++++++
1 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/dlls/comctl32/comboex.c b/dlls/comctl32/comboex.c
index d6b0d8c..9a5115e 100644
--- a/dlls/comctl32/comboex.c
+++ b/dlls/comctl32/comboex.c
@@ -1598,6 +1598,22 @@ static LRESULT COMBOEX_Destroy (COMBOEX_INFO
*infoPtr)
}
+static LRESULT COMBOEX_Enable (COMBOEX_INFO *infoPtr, BOOL enable)
+{
+ TRACE("hwnd=%p, enable=%s\n", infoPtr->hwndSelf, enable ?
"TRUE":"FALSE");
+
+ if (infoPtr->hwndEdit)
+ EnableWindow(infoPtr->hwndEdit, enable);
+
+ EnableWindow(infoPtr->hwndCombo, enable);
+
+ /* Force the control to repaint when the enabled state changes. */
+ InvalidateRect(infoPtr->hwndSelf, NULL, TRUE);
+
+ return 1;
+}
+
+
static LRESULT COMBOEX_MeasureItem (COMBOEX_INFO const *infoPtr,
MEASUREITEMSTRUCT *mis)
{
static const WCHAR strW[] = { 'W', 0 };
@@ -2278,6 +2294,9 @@ COMBOEX_WindowProc (HWND hwnd, UINT uMsg, WPARAM
wParam, LPARAM lParam)
case WM_DESTROY:
return COMBOEX_Destroy (infoPtr);
+ case WM_ENABLE:
+ return COMBOEX_Enable (infoPtr, (BOOL)wParam);
+
case WM_MEASUREITEM:
return COMBOEX_MeasureItem (infoPtr, (MEASUREITEMSTRUCT
*)lParam);
--
1.7.4.1
More information about the wine-patches
mailing list