MFC 4.x 適時地為我們註冊Windows 視窗類別(在
第一次產生該種型式之視窗之前)。這些個Windows 視窗類別的視窗函式各是「視窗所
對應之C++ 類別中的DefWindowProc 成員函式」
AfxEndDeferRegisterClass中是这样的
wndcls.lpfnWndProc = DefWindowProc;
而且WNDCLASS的lpfnWndProc不可能指向一个带this的成员函数啊
第一次產生該種型式之視窗之前)。這些個Windows 視窗類別的視窗函式各是「視窗所
對應之C++ 類別中的DefWindowProc 成員函式」
AfxEndDeferRegisterClass中是这样的
wndcls.lpfnWndProc = DefWindowProc;
而且WNDCLASS的lpfnWndProc不可能指向一个带this的成员函数啊
解决方案 »
- 想把edit box变成combo box的问题
- 如何让一个函数调用另一个消息响应函数
- 一个简单的问题:标题栏上的系统菜单图标、最大/小化按钮、关闭按钮到底是什么东西?
- MDI程序中传入参数问题
- 谁有关于vc 用DCOM实现数据库三层结构的帮助,或某个网址。
- 关于列表控件的一个问题
- 做帮助文件的那个Rtf文件是怎样编辑的?
- (菜鳥問題)在VC中如何連接MySql數據庫?可以用ADO嗎?急急急急..........
- 提问
- VC中对于标题栏的操作?(高手帮忙)
- 请教高手,SymInitialize()和SymLoadModule()这两个函数怎么用?
- 请问如何取得窗口中AcitveX控件的IUnknown接口?
Pointer to the window procedure. You must use the CallWindowProc function to call the window procedure.The WindowProc function is an application-defined function that processes messages sent to a window. The WNDPROC type defines a pointer to this callback function. WindowProc is a placeholder for the application-defined function name. SyntaxLRESULT CALLBACK WindowProc(HWND hwnd,
UINT uMsg,
WPARAM wParam,
LPARAM lParam
);
Parametershwnd
[in] Handle to the window.
uMsg
[in] Specifies the message.
wParam
[in] Specifies additional message information. The contents of this parameter depend on the value of the uMsg parameter.
lParam
[in] Specifies additional message information. The contents of this parameter depend on the value of the uMsg parameter.
Return ValueThe return value is the result of the message processing and depends on the message sent.注:【深入浅出】这个成语的意思是:对内容的理解十分深刻,表达却浅显易懂。
wndcls.lpfnWndProc = DefWindowProc;应该就是SDK中的那个DefWindowProc吧
这样书上不就不对了吗?CWnd::DefWindowProc是个虚函数