📄 myaboutdlg.cpp
字号:
// fileName: myAboutDlg.cpp
// by: zhnyong@21cn.com
// “关于”对话框的程序文件,主要这对话框过程
// 包括头文件
#include "myFileManagement.h"
// 引用外部定义的全局程序实例
extern HINSTANCE hInst;
// 定义全局消息ID号与对话框窗口消息处理过程指针查找表
const dlgMessageProc aboutDlgMessages[]=
{
WM_COMMAND, goCommandAboutDlg,
};
// 对话框窗口过程,必须为回调函数,当对话框收到消息后,会告知Windows CE系统执行对应的消息处理过程
BOOL CALLBACK aboutDlgProc(HWND hWnd, UINT msgCode, WPARAM wParam, LPARAM lParam)
{
INT i;
// 查找对应的消息ID号,并执行相应的消息处理过程,并返回TRUE
for(i=0;i<dim(aboutDlgMessages);i++)
{
if(msgCode==aboutDlgMessages[i].uCode)
return (*aboutDlgMessages[i].functionName)(hWnd, msgCode, wParam, lParam);
}
// 对于不在消息查找表中的消息,对话框过程返回FALSE
return FALSE;
}
// “关于”对话框收到WM_COMMAND消息后的处理过程
BOOL goCommandAboutDlg(HWND hWnd, UINT msgCode, WPARAM wParam, LPARAM lParam)
{
// 获得控件的ID号,为IDCANCEL时,退出对话框
switch(LOWORD(wParam))
{
case IDCANCEL:
EndDialog(hWnd,0);
return TRUE;
break;
}
return 0;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -