- Change the text when riched20.dll cannot be loaded, and also display it with MessageBox, since

it's far too early to be used with I_FatalError. (But since this should always be available on
  every Windows version after 95, this should be a non-issue.)
- Make unknown OS versions default to Windows 2000 instead of Windows 95.

SVN r3802 (trunk)
This commit is contained in:
Randy Heit 2012-08-02 04:00:40 +00:00
parent 4cdf524e6c
commit ede622bb93
3 changed files with 8 additions and 12 deletions

View file

@ -1224,14 +1224,14 @@ int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE nothing, LPSTR cmdline, int n
InitCommonControls (); // Load some needed controls and be pretty under XP InitCommonControls (); // Load some needed controls and be pretty under XP
// We need to load riched20.dll so that we can create the control.
if (NULL == LoadLibrary ("riched20.dll")) if (NULL == LoadLibrary ("riched20.dll"))
{ {
// Technically, it isn't really Internet Explorer that is needed, but this // This should only happen on basic Windows 95 installations, but since we
// is an example of a specific program that will provide riched20.dll. // don't support Windows 95, we have no obligation to provide assistance in
// But considering how much extra stuff needs to be installed to make Windows 95 // getting it installed.
// useable with pretty much any recent software, the chances are high that MessageBoxA(NULL, "Could not load riched20.dll", "ZDoom Error", MB_OK | MB_ICONSTOP);
// the user already has riched20.dll installed. exit(0);
I_FatalError ("Sorry, you need to install Internet Explorer 3 or higher to play ZDoom on Windows 95.");
} }
#if !defined(__GNUC__) && defined(_DEBUG) #if !defined(__GNUC__) && defined(_DEBUG)

View file

@ -607,8 +607,8 @@ void I_DetectOS(void)
if (OSPlatform == os_unknown) if (OSPlatform == os_unknown)
{ {
Printf ("(Assuming Windows 95)\n"); Printf ("(Assuming Windows 2000)\n");
OSPlatform = os_Win95; OSPlatform = os_Win2k;
} }
} }

View file

@ -389,10 +389,6 @@ void Win32Video::DumpAdapters()
{ {
*p = '\0'; *p = '\0';
} }
// Get monitor info from GDI for more details. Windows 95 apparently does not have
// the GetMonitorInfo function. I will leave this like this for now instead of using
// GetProcAddress to see if it's still worth worrying about Windows 95 support.
// (e.g. Will anybody complain that they can't run ZDoom anymore?)
HMONITOR hm = D3D->GetAdapterMonitor(i); HMONITOR hm = D3D->GetAdapterMonitor(i);
MONITORINFOEX mi; MONITORINFOEX mi;
mi.cbSize = sizeof(mi); mi.cbSize = sizeof(mi);