Author: gadamopoulos
Date: Sat Aug  5 10:23:07 2017
New Revision: 75488

URL: http://svn.reactos.org/svn/reactos?rev=75488&view=rev
Log:
[COMCTL32] -BUTTON_PaintWithTheme: Draw checked pushlike buttons as pressed.

Modified:
    trunk/reactos/dll/win32/comctl32/theme_button.c

Modified: trunk/reactos/dll/win32/comctl32/theme_button.c
URL: 
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/comctl32/theme_button.c?rev=75488&r1=75487&r2=75488&view=diff
==============================================================================
--- trunk/reactos/dll/win32/comctl32/theme_button.c     [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/comctl32/theme_button.c     [iso-8859-1] Sat Aug  5 
10:23:07 2017
@@ -471,12 +471,19 @@
 
     if(IsWindowEnabled(hwnd))
     {
-        if(state & BST_PUSHED) drawState = STATE_PRESSED;
-        else if(state & BST_HOT) drawState = STATE_HOT;
-        else if(state & BST_FOCUS) drawState = STATE_DEFAULTED;
-        else drawState = STATE_NORMAL;
-    }
-    else drawState = STATE_DISABLED;
+        if(state & BST_PUSHED) 
+            drawState = STATE_PRESSED;
+        else if ((dwStyle & BS_PUSHLIKE) && (state & 
(BST_CHECKED|BST_INDETERMINATE))) 
+            drawState = STATE_PRESSED;
+        else if(state & BST_HOT) 
+            drawState = STATE_HOT;
+        else if(state & BST_FOCUS) 
+            drawState = STATE_DEFAULTED;
+        else 
+            drawState = STATE_NORMAL;
+    }
+    else 
+        drawState = STATE_DISABLED;
 
 #ifndef __REACTOS__ /* r73873 */
     hDC = hParamDC ? hParamDC : BeginPaint(hwnd, &ps);


Reply via email to