Alexandre Julliard : comctl32: Use the module instance instead of that of the owner window for the toolbar configuration dialog .

Alexandre Julliard julliard at winehq.org
Mon Dec 21 09:39:46 CST 2009


Module: wine
Branch: master
Commit: 6fd93a6c7e3ca9af51dcc0e161f9d5c9167feb84
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=6fd93a6c7e3ca9af51dcc0e161f9d5c9167feb84

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Mon Dec 21 11:20:19 2009 +0100

comctl32: Use the module instance instead of that of the owner window for the toolbar configuration dialog.

---

 dlls/comctl32/toolbar.c |   15 ++-------------
 1 files changed, 2 insertions(+), 13 deletions(-)

diff --git a/dlls/comctl32/toolbar.c b/dlls/comctl32/toolbar.c
index 1cbdd6f..d5ca524 100644
--- a/dlls/comctl32/toolbar.c
+++ b/dlls/comctl32/toolbar.c
@@ -3156,8 +3156,6 @@ TOOLBAR_Customize (TOOLBAR_INFO *infoPtr)
 {
     CUSTDLG_INFO custInfo;
     LRESULT ret;
-    LPCVOID template;
-    HRSRC hRes;
     NMHDR nmhdr;
 
     custInfo.tbInfo = infoPtr;
@@ -3166,17 +3164,8 @@ TOOLBAR_Customize (TOOLBAR_INFO *infoPtr)
     /* send TBN_BEGINADJUST notification */
     TOOLBAR_SendNotify (&nmhdr, infoPtr, TBN_BEGINADJUST);
 
-    if (!(hRes = FindResourceW (COMCTL32_hModule,
-                                MAKEINTRESOURCEW(IDD_TBCUSTOMIZE),
-                                (LPWSTR)RT_DIALOG)))
-	return FALSE;
-
-    if(!(template = LoadResource (COMCTL32_hModule, hRes)))
-	return FALSE;
-
-    ret = DialogBoxIndirectParamW ((HINSTANCE)GetWindowLongPtrW(infoPtr->hwndSelf, GWLP_HINSTANCE),
-                                   template, infoPtr->hwndSelf, TOOLBAR_CustomizeDialogProc,
-                                   (LPARAM)&custInfo);
+    ret = DialogBoxParamW (COMCTL32_hModule, MAKEINTRESOURCEW(IDD_TBCUSTOMIZE),
+                           infoPtr->hwndSelf, TOOLBAR_CustomizeDialogProc, (LPARAM)&custInfo);
 
     /* send TBN_ENDADJUST notification */
     TOOLBAR_SendNotify (&nmhdr, infoPtr, TBN_ENDADJUST);




More information about the wine-cvs mailing list