Changeset - r17658:060232d90fcd
[Not reviewed]
master
0 1 0
terkhen - 13 years ago 2011-05-09 20:29:01
terkhen@openttd.org
(svn r22440) -Change: [Windows] Remove Cancel button from information messages.
1 file changed with 1 insertions and 3 deletions:
0 comments (0 inline, 0 general)
src/os/windows/win32.cpp
Show inline comments
 
@@ -367,27 +367,25 @@ void ShowInfo(const char *str)
 
		if (strlen(str) > 2048) {
 
			/* The minimum length of the help message is 2048. Other messages sent via
 
			 * ShowInfo are much shorter, or so long they need this way of displaying
 
			 * them anyway. */
 
			_help_msg = str;
 
			DialogBox(GetModuleHandle(NULL), MAKEINTRESOURCE(101), NULL, HelpDialogFunc);
 
		} else {
 
#if defined(UNICODE)
 
			/* We need to put the text in a seperate buffer because the default
 
			 * buffer in MB_TO_WIDE might not be large enough (512 chars) */
 
			wchar_t help_msgW[8192];
 
#endif
 
			if (MessageBox(GetActiveWindow(), MB_TO_WIDE_BUFFER(str, help_msgW, lengthof(help_msgW)), _T("OpenTTD"), MB_ICONINFORMATION | MB_OKCANCEL) == IDCANCEL) {
 
				CreateConsole();
 
			}
 
			MessageBox(GetActiveWindow(), MB_TO_WIDE_BUFFER(str, help_msgW, lengthof(help_msgW)), _T("OpenTTD"), MB_ICONINFORMATION | MB_OK);
 
		}
 
		MyShowCursor(old);
 
	}
 
}
 

	
 
#if defined(WINCE)
 
int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdLine, int nCmdShow)
 
#else
 
int APIENTRY WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
 
#endif
 
{
 
	int argc;
0 comments (0 inline, 0 general)