-
Notifications
You must be signed in to change notification settings - Fork 0
/
MainWin32.cpp
37 lines (29 loc) · 1.49 KB
/
MainWin32.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#include <winsock2.h>
#include "gui/Application.h"
#include "gui/WndProc.h"
#include <Windows.h>
#include <string>
#pragma comment(lib, "comctl32.lib")
#if defined _M_IX86
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='x86' publicKeyToken='6595b64144ccf1df' language='*'\"")
#elif defined _M_IA64
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='ia64' publicKeyToken='6595b64144ccf1df' language='*'\"")
#elif defined _M_X64
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='amd64' publicKeyToken='6595b64144ccf1df' language='*'\"")
#else
#pragma comment(linker, "/manifestdependency:\"type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'\"")
#endif
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nShowCmd)
{
srand(unsigned(time(NULL)));
if (Application::IsAlreadyRunning())
{
return EXIT_FAILURE;
}
//INITCOMMONCONTROLSEX icex;
//icex.dwSize = sizeof(INITCOMMONCONTROLSEX);
//icex.dwICC = ICC_USEREX_CLASSES;
//InitCommonControlsEx(&icex);
Application app(NULL, hInstance, nShowCmd, WndProc, 300, 400, CS_HREDRAW | CS_VREDRAW | CS_DBLCLKS);
return app.Run();
}