Make the controls send notifications to the parent window passed to
them in CREATESTRUCT. Based on a treeview patch by Igor Grahek.
diff --git a/dlls/comctl32/treeview.c b/dlls/comctl32/treeview.c
index f93ab93..2a025eb 100644
--- a/dlls/comctl32/treeview.c
+++ b/dlls/comctl32/treeview.c
@@ -4718,7 +4718,7 @@
/* Create/Destroy *******************************************************/
static LRESULT
-TREEVIEW_Create(HWND hwnd)
+TREEVIEW_Create(HWND hwnd, const CREATESTRUCTW *lpcs)
{
RECT rcClient;
TREEVIEW_INFO *infoPtr;
@@ -4797,7 +4797,7 @@
infoPtr->root->iLevel = -1;
infoPtr->root->visibleOrder = -1;
- infoPtr->hwndNotify = GetParent(hwnd);
+ infoPtr->hwndNotify = lpcs->hwndParent;
#if 0
infoPtr->bTransparent = ( GetWindowLongA( hwnd, GWL_STYLE) & TBSTYLE_FLAT);
#endif
@@ -5179,7 +5179,7 @@
else
{
if (uMsg == WM_CREATE)
- TREEVIEW_Create(hwnd);
+ TREEVIEW_Create(hwnd, (LPCREATESTRUCTW)lParam);
else
goto def;
}