(svn r8309) [WinCE] -Fix: WinCE doesn't know resolution changing
-Fix: WinCE doesn't know GetKeyboardState -Fix: made a replacement of GetCurrentDirectory, where CurDir is assumed to be the dir the executable is located (esoftinteractive.com) -Fix: the GCC compiler is more happy if the WinMain is called that -Fix: a really old typo (missing ')') ;) -Fix: GdiFlush() isn't supported on WinCE
This commit is contained in:
@@ -60,7 +60,7 @@ bool LoadLibraryList(Function proc[], const char *dll)
|
||||
while (*dll++ != '\0');
|
||||
if (*dll == '\0') break;
|
||||
#if defined(WINCE)
|
||||
p = GetProcAddress(lib, MB_TO_WIDE(dll);
|
||||
p = GetProcAddress(lib, MB_TO_WIDE(dll));
|
||||
#else
|
||||
p = GetProcAddress(lib, dll);
|
||||
#endif
|
||||
@@ -866,7 +866,12 @@ void ShowInfo(const char *str)
|
||||
int _set_error_mode(int);
|
||||
#endif
|
||||
|
||||
int APIENTRY _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
|
||||
#if defined(WINCE)
|
||||
int APIENTRY WinMain
|
||||
#else
|
||||
int APIENTRY _tWinMain
|
||||
#endif
|
||||
(HINSTANCE hInstance, HINSTANCE hPrevInstance,
|
||||
LPTSTR lpCmdLine, int nCmdShow)
|
||||
{
|
||||
int argc;
|
||||
@@ -912,6 +917,22 @@ int APIENTRY _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
|
||||
return 0;
|
||||
}
|
||||
|
||||
#if defined(WINCE)
|
||||
void GetCurrentDirectoryW(int length, wchar_t *path)
|
||||
{
|
||||
wchar_t *pDest = NULL;
|
||||
/* Get the name of this module */
|
||||
GetModuleFileName(NULL, path, length);
|
||||
|
||||
/* Remove the executable name, this we call CurrentDir */
|
||||
pDest = wcsrchr(path, '\\');
|
||||
if (pDest != NULL) {
|
||||
int result = pDest - path + 1;
|
||||
path[result] = '\0';
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void DeterminePaths(void)
|
||||
{
|
||||
char *s, *cfg;
|
||||
|
Reference in New Issue
Block a user