首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > VC/MFC >

怎么实现鼠标焦点不在对话框时,销毁该对话框

2012-04-03 
如何实现鼠标焦点不在对话框时,销毁该对话框点击edit空间弹出字定义的键盘对话框,如何实现鼠标焦点不在该

如何实现鼠标焦点不在对话框时,销毁该对话框
点击edit空间弹出字定义的键盘对话框,如何实现鼠标焦点不在该对话框时,销毁该对话框


[解决办法]
::GetFocus()
Return Values
The handle to the window with the keyboard focus indicates success. NULL indicates that the calling thread’s message queue does not have an associated window with the keyboard focus. 

看返回的句柄是不是对话框的

[解决办法]
DestroyWindow销毁
[解决办法]
WM_KILLFOCUS

热点排行