- prfdp->hIcon = LoadIconW(NULL, (LPCWSTR)IDI_WINLOGO);
- SendMessageW(hwnd, WM_SETICON, ICON_BIG, (LPARAM)prfdp->hIcon);
- SendMessageW(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)prfdp->hIcon);
+ prfdp->hIcon = LoadIconW(shell32_hInstance, MAKEINTRESOURCEW(IDI_SHELL_RUN));
+ /*
+ * NOTE: Starting Windows Vista, the "Run File" dialog gets a
+ * title icon that remains the same as the default one, even if
+ * the user specifies a custom icon.
+ * Since we currently imitate Windows 2003, therefore do not show
+ * any title icon.
+ */
+ // SendMessageW(hwnd, WM_SETICON, ICON_BIG, (LPARAM)prfdp->hIcon);
+ // SendMessageW(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)prfdp->hIcon);
+ SendMessageW(GetDlgItem(hwnd, IDC_RUNDLG_ICON), STM_SETICON, (WPARAM)prfdp->hIcon, 0);