Fix to ComboBoxEx processing of WM_ENABLE message=0A=

Richard Bradbrook richard at bradders2000.co.uk
Sun Jul 31 18:06:25 CDT 2011


=0A=
---=0A=
 dlls/comctl32/comboex.c |   19 +++++++++++++++++++=0A=
 1 files changed, 19 insertions(+), 0 deletions(-)=0A=
=0A=
diff --git a/dlls/comctl32/comboex.c b/dlls/comctl32/comboex.c=0A=
index d6b0d8c..9a5115e 100644=0A=
--- a/dlls/comctl32/comboex.c=0A=
+++ b/dlls/comctl32/comboex.c=0A=
@@ -1598,6 +1598,22 @@ static LRESULT COMBOEX_Destroy (COMBOEX_INFO =
*infoPtr)=0A=
 }=0A=
 =0A=
 =0A=
+static LRESULT COMBOEX_Enable (COMBOEX_INFO *infoPtr, BOOL enable)=0A=
+{=0A=
+    TRACE("hwnd=3D%p, enable=3D%s\n", infoPtr->hwndSelf, enable ? =
"TRUE":"FALSE");=0A=
+=0A=
+    if (infoPtr->hwndEdit)=0A=
+       EnableWindow(infoPtr->hwndEdit, enable);=0A=
+=0A=
+    EnableWindow(infoPtr->hwndCombo, enable);=0A=
+=0A=
+    /* Force the control to repaint when the enabled state changes. */=0A=
+    InvalidateRect(infoPtr->hwndSelf, NULL, TRUE);=0A=
+=0A=
+    return 1;=0A=
+}=0A=
+=0A=
+=0A=
 static LRESULT COMBOEX_MeasureItem (COMBOEX_INFO const *infoPtr, =
MEASUREITEMSTRUCT *mis)=0A=
 {=0A=
     static const WCHAR strW[] =3D { 'W', 0 };=0A=
@@ -2278,6 +2294,9 @@ COMBOEX_WindowProc (HWND hwnd, UINT uMsg, WPARAM =
wParam, LPARAM lParam)=0A=
 	case WM_DESTROY:=0A=
 	    return COMBOEX_Destroy (infoPtr);=0A=
 =0A=
+	case WM_ENABLE:=0A=
+	    return COMBOEX_Enable (infoPtr, (BOOL)wParam);=0A=
+=0A=
         case WM_MEASUREITEM:=0A=
             return COMBOEX_MeasureItem (infoPtr, (MEASUREITEMSTRUCT =
*)lParam);=0A=
 =0A=
-- =0A=
1.7.4.1=0A=
=0A=

------=_NextPart_000_0011_01CC516E.D44A3FF0--




More information about the wine-patches mailing list