www.gusucode.com > MFC编程,实现类似VC6.0的界面设计源码程序 > MFC编程,实现类似VC6.0的界面设计源码程序/VCface/bardemo/MyDlg.cpp
// MyDlg.cpp : implementation file // #include "stdafx.h" #include "BarDemo.h" #include "MyDlg.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] = __FILE__; #endif ///////////////////////////////////////////////////////////////////////////// // CMyDlg dialog IMPLEMENT_DYNCREATE(CMyDlg, CDialog) CMyDlg::CMyDlg(CWnd* pParent /*=NULL*/) : CDialog(CMyDlg::IDD, pParent) { //{{AFX_DATA_INIT(CMyDlg) // NOTE: the ClassWizard will add member initialization here //}}AFX_DATA_INIT } void CMyDlg::DoDataExchange(CDataExchange* pDX) { CDialog::DoDataExchange(pDX); //{{AFX_DATA_MAP(CMyDlg) // NOTE: the ClassWizard will add DDX and DDV calls here //}}AFX_DATA_MAP } BEGIN_MESSAGE_MAP(CMyDlg, CDialog) //{{AFX_MSG_MAP(CMyDlg) //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CMyDlg message handlers BOOL CMyDlg::PreTranslateMessage(MSG* pMsg) { if(pMsg->message == WM_KEYDOWN && pMsg->wParam == VK_RETURN) { return TRUE; } return CDialog::PreTranslateMessage(pMsg); }