1 //+---------------------------------------------------------------------------
5 #define __UNKNOWN_APP 0
6 #define __CONSOLE_APP 1
8 void __set_app_type(int);
9 void _controlfp(unsigned a
, unsigned b
);
15 STARTUPINFO startinfo
;
19 __set_app_type(__GUI_APP
);
20 _controlfp(0x10000, 0x30000);
22 szCmd
= GetCommandLine();
33 while (*szCmd
&& ' ' != *szCmd
)
40 GetStartupInfo(&startinfo
);
41 fShow
= startinfo
.wShowWindow
;
42 if (0 == (startinfo
.dwFlags
& STARTF_USESHOWWINDOW
))
43 fShow
= SW_SHOWDEFAULT
;
45 ret
= WinMain(GetModuleHandle(NULL
), NULL
, szCmd
, fShow
);
49 int _runwinmain(int argc
, char **argv
)
56 szCmd
= strstr(p
, argv
[1]);
59 else if (szCmd
> p
&& szCmd
[-1] == '\"')
61 return WinMain(GetModuleHandle(NULL
), NULL
, szCmd
, SW_SHOWDEFAULT
);