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

📄 statuspane.cpp

📁 讲mfc的书
💻 CPP
字号:
// StatusPane.cpp : implementation file
//

#include "stdafx.h"
#include "split.h"
#include "StatusPane.h"

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

/////////////////////////////////////////////////////////////////////////////
// CStatusPane

IMPLEMENT_DYNCREATE(CStatusPane, CView)

CStatusPane::CStatusPane()
{
}

CStatusPane::~CStatusPane()
{
}


BEGIN_MESSAGE_MAP(CStatusPane, CView)
	//{{AFX_MSG_MAP(CStatusPane)
		// NOTE - the ClassWizard will add and remove mapping macros here.
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

CBrush CStatusPane::redbr;

/////////////////////////////////////////////////////////////////////////////
// CStatusPane drawing

void CStatusPane::OnDraw(CDC* pDC)
{
	CDocument* pDoc = GetDocument();
	pDC->SetBkMode(TRANSPARENT);
	pDC->TextOut(0,0,"Status Nominal");
}

/////////////////////////////////////////////////////////////////////////////
// CStatusPane diagnostics

#ifdef _DEBUG
void CStatusPane::AssertValid() const
{
	CView::AssertValid();
}

void CStatusPane::Dump(CDumpContext& dc) const
{
	CView::Dump(dc);
}
#endif //_DEBUG

/////////////////////////////////////////////////////////////////////////////
// CStatusPane message handlers

BOOL CStatusPane::PreCreateWindow(CREATESTRUCT& cs) 
{
    if (!redbr.m_hObject) redbr.CreateSolidBrush(RGB(0xFF,0,0));
	cs.lpszClass=AfxRegisterWndClass(0,AfxGetApp()->LoadStandardCursor(IDC_ARROW),(HBRUSH)redbr.m_hObject);	
	return CView::PreCreateWindow(cs);
}

void CStatusPane::OnInitialUpdate() 
{
	CView::OnInitialUpdate();
	
    btn.Create("Reset",BS_PUSHBUTTON|WS_VISIBLE,CRect(50,25,150,60),this,1);
}

⌨️ 快捷键说明

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