diff --git a/dll/shellext/zipfldr/CZipExtract.cpp b/dll/shellext/zipfldr/CZipExtract.cpp index 24a744f2e2d..20a8087a029 100644 --- a/dll/shellext/zipfldr/CZipExtract.cpp +++ b/dll/shellext/zipfldr/CZipExtract.cpp @@ -331,10 +331,23 @@ public: }; + /* NOTE: This callback is needed to set large icon correctly. */ + static INT CALLBACK s_PropSheetCallbackProc(HWND hwndDlg, UINT uMsg, LPARAM lParam) + { + if (uMsg == PSCB_INITIALIZED) + { + HICON hIcon = LoadIconW(_AtlBaseModule.GetResourceInstance(), MAKEINTRESOURCEW(IDI_ZIPFLDR)); + CWindow dlg(hwndDlg); + dlg.SetIcon(hIcon, TRUE); + } + + return 0; + } + void runWizard() { PROPSHEETHEADERW psh = { sizeof(psh), 0 }; - psh.dwFlags = PSH_WIZARD97 | PSH_HEADER | PSH_USEICONID; + psh.dwFlags = PSH_WIZARD97 | PSH_HEADER | PSH_USEICONID | PSH_USECALLBACK; psh.hInstance = _AtlBaseModule.GetResourceInstance(); CExtractSettingsPage extractPage(this, &m_Password); @@ -350,6 +363,7 @@ public: psh.pszIcon = MAKEINTRESOURCE(IDI_ZIPFLDR); psh.pszbmWatermark = MAKEINTRESOURCE(IDB_WATERMARK); psh.pszbmHeader = MAKEINTRESOURCE(IDB_HEADER); + psh.pfnCallback = s_PropSheetCallbackProc; PropertySheetW(&psh); }