comctl32: Use the module instance instead of that of the owner window for the toolbar configuration dialog.
This commit is contained in:
parent
29c0ecfd1c
commit
6fd93a6c7e
|
@ -3156,8 +3156,6 @@ TOOLBAR_Customize (TOOLBAR_INFO *infoPtr)
|
||||||
{
|
{
|
||||||
CUSTDLG_INFO custInfo;
|
CUSTDLG_INFO custInfo;
|
||||||
LRESULT ret;
|
LRESULT ret;
|
||||||
LPCVOID template;
|
|
||||||
HRSRC hRes;
|
|
||||||
NMHDR nmhdr;
|
NMHDR nmhdr;
|
||||||
|
|
||||||
custInfo.tbInfo = infoPtr;
|
custInfo.tbInfo = infoPtr;
|
||||||
|
@ -3166,17 +3164,8 @@ TOOLBAR_Customize (TOOLBAR_INFO *infoPtr)
|
||||||
/* send TBN_BEGINADJUST notification */
|
/* send TBN_BEGINADJUST notification */
|
||||||
TOOLBAR_SendNotify (&nmhdr, infoPtr, TBN_BEGINADJUST);
|
TOOLBAR_SendNotify (&nmhdr, infoPtr, TBN_BEGINADJUST);
|
||||||
|
|
||||||
if (!(hRes = FindResourceW (COMCTL32_hModule,
|
ret = DialogBoxParamW (COMCTL32_hModule, MAKEINTRESOURCEW(IDD_TBCUSTOMIZE),
|
||||||
MAKEINTRESOURCEW(IDD_TBCUSTOMIZE),
|
infoPtr->hwndSelf, TOOLBAR_CustomizeDialogProc, (LPARAM)&custInfo);
|
||||||
(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);
|
|
||||||
|
|
||||||
/* send TBN_ENDADJUST notification */
|
/* send TBN_ENDADJUST notification */
|
||||||
TOOLBAR_SendNotify (&nmhdr, infoPtr, TBN_ENDADJUST);
|
TOOLBAR_SendNotify (&nmhdr, infoPtr, TBN_ENDADJUST);
|
||||||
|
|
Loading…
Reference in New Issue