⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 myscreensvr.cpp

📁 "Visual C++.net实践与提高-深入Windows编程"的源代码
💻 CPP
字号:
// MyScreenSvr.cpp : Defines the class behaviors for the application.
//

#include "stdafx.h"
#include "MyScreenSvr.h"
#include "MyScreenSvrDlg.h"
#include "MyScreenSvrWnd.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CMyScreenSvrApp

BEGIN_MESSAGE_MAP(CMyScreenSvrApp, CScreenSvrApp)
	//{{AFX_MSG_MAP(CMyScreenSvrApp)
		// NOTE - the ClassWizard will add and remove mapping macros here.
		//    DO NOT EDIT what you see in these blocks of generated code!
	//}}AFX_MSG
	ON_COMMAND(ID_HELP, CWinApp::OnHelp)
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CMyScreenSvrApp construction

CMyScreenSvrApp::CMyScreenSvrApp(void)
{
}

/////////////////////////////////////////////////////////////////////////////
// The one and only CMyScreenSvrApp object

CMyScreenSvrApp theApp;

/////////////////////////////////////////////////////////////////////////////
// CMyScreenSvrApp initialization

BOOL CMyScreenSvrApp::InitInstance()
{
	return CScreenSvrApp::InitInstance() ;
}

BOOL CMyScreenSvrApp::OpenConfigWnd(HWND hParentWnd)
{
	CWnd *pWndParent = CWnd::FromHandle(hParentWnd);
	CMyScreenSvrDlg dlg(pWndParent);
//	m_pMainWnd = &dlg;  // 删除本句,则设置对话框置于它的父窗口之上.
	int nResponse = dlg.DoModal();
	if (nResponse == IDOK)
	{
		// TODO: Place code here to handle when the dialog is
		//  dismissed with OK
	}
	return FALSE ;			// Exit Appliction: FALSE; True: enter messages Processing
}

BOOL CMyScreenSvrApp::OpenScreenSvrWnd(HWND hParentWnd)
{
	CWnd *pWndParent = CWnd::FromHandle(hParentWnd);
	CMyScreenSvrWnd * pSCRWnd = new CMyScreenSvrWnd(pWndParent) ;
	pSCRWnd->Create();
	m_pMainWnd = pSCRWnd;
	return TRUE ;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -