myscroll.cpp

来自「B-树演示程序(vc++)可执行程序.rar」· C++ 代码 · 共 42 行

CPP
42
字号
// MyScroll.cpp : implementation file
//

#include "stdafx.h"
#include "BTreeDemo.h"
#include "MyScroll.h"

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

/////////////////////////////////////////////////////////////////////////////
// CMyScroll

CMyScroll::CMyScroll()
{
}

CMyScroll::~CMyScroll()
{
}


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

/////////////////////////////////////////////////////////////////////////////
// CMyScroll message handlers
void CMyScroll::DrawItem(LPDRAWITEMSTRUCT lpDrawItemStruct)  {
    CDC* pDC      = CDC::FromHandle(lpDrawItemStruct->hDC);
	CRect rc	  = lpDrawItemStruct->rcItem;
	CBrush brush;
	brush.CreateSolidBrush(RGB(100,100,233));
	pDC->FillRect(rc,&brush);
	CMyScroll::DrawItem(LPDRAWITEMSTRUCT lpDrawItemStruct);

}

⌨️ 快捷键说明

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