This test was only needed for Windows 9x, as Windows 2000 shipped with Internet Explorer 5.01 and Windows ME shipped with 5.5:
https://msdn.microsoft.com/en-us/library/windows/desktop/hh298349.aspx * propsheet.cc (GetPROPSHEETHEADERSize): Remove. (PropSheet::Create): Use sizeof (PROPSHEETHEADER) unconditionally. * win32.h (_WIN32_IE): Remove. Signed-off-by: Yaakov Selkowitz <yselk...@redhat.com> --- propsheet.cc | 45 +-------------------------------------------- win32.h | 4 ---- 2 files changed, 1 insertion(+), 48 deletions(-) diff --git a/propsheet.cc b/propsheet.cc index 976aefb..016f9d3 100644 --- a/propsheet.cc +++ b/propsheet.cc @@ -294,49 +294,6 @@ PropSheetProc (HWND hwndDlg, UINT uMsg, LPARAM lParam) return TRUE; } -static DWORD -GetPROPSHEETHEADERSize () -{ - // For compatibility with all versions of comctl32.dll, we have to do this. - - DLLVERSIONINFO vi; - HMODULE mod; - DLLGETVERSIONPROC DllGetVersion; - DWORD retval = 0; - - - // This 'isn't safe' in a DLL, according to MSDN - mod = LoadLibrary ("comctl32.dll"); - - DllGetVersion = (DLLGETVERSIONPROC) GetProcAddress (mod, "DllGetVersion"); - if (DllGetVersion == NULL) - { - // Something's wildly broken, punt. - retval = PROPSHEETHEADER_V1_SIZE; - } - else - { - vi.cbSize = sizeof (DLLVERSIONINFO); - DllGetVersion (&vi); - - if ((vi.dwMajorVersion < 4) || - ((vi.dwMajorVersion == 4) && (vi.dwMinorVersion < 71))) - { - // Recent. - retval = sizeof (PROPSHEETHEADER); - } - else - { - // Old (== Win95/NT4 w/o IE 4 or better) - retval = PROPSHEETHEADER_V1_SIZE; - } - } - - FreeLibrary (mod); - - return retval; -} - bool PropSheet::Create (const Window * Parent, DWORD Style) { @@ -344,7 +301,7 @@ PropSheet::Create (const Window * Parent, DWORD Style) PageHandles = CreatePages (); - p.dwSize = GetPROPSHEETHEADERSize (); + p.dwSize = sizeof (PROPSHEETHEADER); p.dwFlags = PSH_NOAPPLYNOW | PSH_WIZARD | PSH_USECALLBACK /*| PSH_MODELESS */ | PSH_USEICONID; if (Parent != NULL) diff --git a/win32.h b/win32.h index d271748..a6b3316 100644 --- a/win32.h +++ b/win32.h @@ -49,10 +49,6 @@ #define DECLSPEC_IMPORT #define WINBASEAPI -/* Require at least Internet Explorer 3, in order to have access to - * sufficient Windows Common Controls features from <commctrl.h> . */ -#define _WIN32_IE 0x0300 - #include <windows.h> /* FIXME: The use of _access(fname, 0) as an existence check should be -- 2.6.2