[PATCH v2 04/10] comctl32/button: Implement BCM_GETSPLITINFO
Gabriel Ivăncescu
gabrielopcode at gmail.com
Wed Apr 3 12:06:27 CDT 2019
Signed-off-by: Gabriel Ivăncescu <gabrielopcode at gmail.com>
---
dlls/comctl32/button.c | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/dlls/comctl32/button.c b/dlls/comctl32/button.c
index 4b8a8f4..213ab29 100644
--- a/dlls/comctl32/button.c
+++ b/dlls/comctl32/button.c
@@ -466,6 +466,9 @@ static LRESULT CALLBACK BUTTON_WindowProc(HWND hWnd, UINT uMsg, WPARAM wParam, L
infoPtr->hwnd = hWnd;
infoPtr->parent = cs->hwndParent;
infoPtr->style = cs->style;
+ infoPtr->split_style = BCSS_STRETCH;
+ infoPtr->glyph = (HIMAGELIST)0x36; /* Marlett down arrow char code */
+ infoPtr->glyph_size.cx = get_default_glyph_size(infoPtr);
return DefWindowProcW(hWnd, uMsg, wParam, lParam);
}
@@ -880,6 +883,22 @@ static LRESULT CALLBACK BUTTON_WindowProc(HWND hWnd, UINT uMsg, WPARAM wParam, L
return TRUE;
}
+ case BCM_GETSPLITINFO:
+ {
+ BUTTON_SPLITINFO *info = (BUTTON_SPLITINFO*)lParam;
+
+ if (!info) return FALSE;
+
+ if (info->mask & BCSIF_STYLE)
+ info->uSplitStyle = infoPtr->split_style;
+ if (info->mask & (BCSIF_GLYPH | BCSIF_IMAGE))
+ info->himlGlyph = infoPtr->glyph;
+ if (info->mask & BCSIF_SIZE)
+ info->size = infoPtr->glyph_size;
+
+ return TRUE;
+ }
+
case BM_GETCHECK:
return infoPtr->state & 3;
--
2.20.1
More information about the wine-devel
mailing list