class MYTrunk
{   typedef DWORD (your_class::* sfp_FP4)(DWORD, DWORD, DWORD, DWORD);   template<typename T>
DWORD (WINAPI* sfp4(T f))(DWORD, DWORD, DWORD, DWORD) // 适用于4参数的函数
{
DWORD dwID = *(DWORD*)(VOID*)&f; LPBYTE pByte = new BYTE[MAX_SFP_CODE_SIZE];
if( pByte == NULL )
return NULL; fp4List.push_back((sfp_FP4)f);
mapFP.insert(std::pair<DWORD, DWORD>(dwID, (DWORD)pByte)); memcpy( pByte, Code4, sizeof(Code4));
*(DWORD*)&pByte[20] = (DWORD)&m_pObj;
*(DWORD*)&pByte[28] = (DWORD)&m_fp4List.back(); return (DWORD(WINAPI*)(DWORD,DWORD,DWORD,DWORD))pByte;
}        template<typename your_class>
CONST BYTE TSFPTrunk<your_class>::Code4[MAX_SFP_CODE_SIZE] = 
{ 0x8b, 0x44, 0x24, 0x10, 0x8b, 0x4c, 0x24, 0x0c,
0x8b, 0x54, 0x24, 0x08, 0x50, 0x8b, 0x44, 0x24, 
0x08, 0x51, 0x8b, 0x0d, 0x94, 0x64, 0x41, 0x00,
0x52, 0x50, 0xff, 0x15, 0x00, 0x00, 0x00, 0x00, 
0xc2, 0x10, 0x00, 0x90, 0x90, 0x90, 0x90, 0x90, 
}; 
}// 创建和注册窗口如下
WNDCLASSEX wcex; wcex.cbSize = sizeof(WNDCLASSEX);
wcex.style = CS_HREDRAW | CS_VREDRAW | CS_DBLCLKS;
wcex.lpfnWndProc = (WNDPROC)(m_Trunk.sfp4(&vEngine::WindowWrap::WndProc)); wcex.cbClsExtra = 0;
wcex.cbWndExtra = 0;
wcex.hInstance = hInst;
wcex.hIcon = hIcon;
wcex.hCursor = m_hCursorCurrent;
wcex.hbrBackground = (HBRUSH)GetStockObject(BLACK_BRUSH);
wcex.lpszMenuName = 0;
wcex.lpszClassName = szCaption;
wcex.hIconSm = 0;// LoadIcon(wcex.hInstance, MAKEINTRESOURCE(IDI_SMALL));

if( 0 == RegisterClassEx(&wcex) ) 
{
ERR(_T("error register window class"));
//OutputDebugString(_T("error register window class"));
return FALSE;
}     m_hWnd = ::CreateWindow(szCaption, szCaption,     WS_OVERLAPPED|WS_CAPTION|WS_MINIMIZEBOX|WS_SYSMENU,
CW_USEDEFAULT, CW_USEDEFAULT, m_nWidth, m_nHeight, NULL, NULL, hInst, NULL);

这样注册的窗口回调函数无法响应, 导致创建窗口是被, GetLastError() == 0 
请大侠帮忙看看
窗口回调函数的问题