这是我的代码
// hook.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <windows.h>
#include <iostream>
using namespace std;
LRESULT CALLBACK GetMsgProc(int code, WPARAM wParam, LPARAM lParam);
int _tmain(int argc, _TCHAR* argv[]){
int __;
cout << "Hallo World" << endl;
SetWindowsHookEx(WH_GETMESSAGE, GetMsgProc, 0, 0);
cin >> __;
return 0;
}
LRESULT CALLBACK GetMsgProc(int code, WPARAM wParam, LPARAM lParam){
cout << code << endl;
return 0;
}
我正在尝试获取 WM_PAINT 事件...目前我正在尝试捕获所有事件。我在哪里失踪?