/
UltraSpy.cpp
45 lines (33 loc) · 908 Bytes
/
UltraSpy.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
38
39
40
41
42
43
44
45
// IESpy.cpp : Defines the entry point for the application.
//
#include "stdafx.h"
#include "resource.h"
#include "UltraSpy.h"
#include "MainDlg.h"
CComModule _Module;
int APIENTRY WinMain(HINSTANCE hInstance,
HINSTANCE hPrevInstance,
LPSTR lpCmdLine,
int nCmdShow)
{
lpCmdLine = GetCommandLine(); //this line necessary for _ATL_MIN_CRT
HRESULT hRes = CoInitialize(NULL);
_ASSERTE(SUCCEEDED(hRes));
_Module.Init(0, hInstance, &LIBID_ATLLib);
CMainDlg mainDlg;
g_pMainWin = &mainDlg;
mainDlg.Create(NULL);
mainDlg.ShowWindow(SW_SHOW);
MSG msg;
while (GetMessage(&msg, 0, 0, 0))
{
if (!IsDialogMessage(mainDlg, &msg))
{
TranslateMessage(&msg);
DispatchMessage(&msg);
}
}
_Module.Term();
CoUninitialize();
return msg.wParam;
}