?? childfrm.cpp
字號:
// ChildFrm.cpp : implementation of the CChildFrame class
//
#include "stdafx.h"
#include "Kvip.h"
#include "ChildFrm.h"
#include "MainFrm.H"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
#include "MyMdi.H"
/////////////////////////////////////////////////////////////////////////////
// CChildFrame
IMPLEMENT_DYNCREATE(CChildFrame, CMDIChildWnd)
BEGIN_MESSAGE_MAP(CChildFrame, CMDIChildWnd)
//{{AFX_MSG_MAP(CChildFrame)
ON_WM_CLOSE()
ON_WM_SHOWWINDOW()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CChildFrame construction/destruction
CChildFrame::CChildFrame()
{
// TODO: add member initialization code here
}
CChildFrame::~CChildFrame()
{
}
/////////////////////////////////////////////////////////////////////////////
// CChildFrame diagnostics
#ifdef _DEBUG
void CChildFrame::AssertValid() const
{
CMDIChildWnd::AssertValid();
}
void CChildFrame::Dump(CDumpContext& dc) const
{
CMDIChildWnd::Dump(dc);
}
#endif //_DEBUG
/////////////////////////////////////////////////////////////////////////////
// CChildFrame message handlers
void CChildFrame::ActivateFrame(int nCmdShow)
{
// TODO: Add your specialized code here and/or call the base class
CString strName;
CMyMdi mdi;
CMDIChildWnd::ActivateFrame(nCmdShow);
//strName = ((CMainFrame*)AfxGetMainWnd())->m_Mdi.GetName(this);
strName = mdi.GetName((CWnd*)this);
SetWindowText(strName);
}
void CChildFrame::OnClose()
{
// TODO: Add your message handler code here and/or call default
CMyMdi mdi;
if(mdi.ChildClose((CWnd*)this))
{
CMDIChildWnd::OnClose();
}
}
void CChildFrame::OnShowWindow(BOOL bShow, UINT nStatus)
{
CMyMdi mdi;
if(bShow && mdi.GetCount() == 1)
ShowWindow(SW_MAXIMIZE);
else
CMDIChildWnd::OnShowWindow(bShow, nStatus);
// TODO: Add your message handler code here
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -