blob: 06dcc6b962d91cda0377fd0115aadda7b55a521d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
// ResizablePage.cpp : implementation file
//
/////////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2000-2002 by Paolo Messina
// (http://www.geocities.com/ppescher - ppescher@yahoo.com)
//
// The contents of this file are subject to the Artistic License (the "License").
// You may not use this file except in compliance with the License.
// You may obtain a copy of the License at:
// http://www.opensource.org/licenses/artistic-license.html
//
// If you find this code useful, credits would be nice!
//
/////////////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "ResizablePage.h"
/////////////////////////////////////////////////////////////////////////////
// CResizablePage
IMPLEMENT_DYNCREATE(CResizablePage, CPropertyPage)
CResizablePage::CResizablePage()
{
}
CResizablePage::CResizablePage(UINT nIDTemplate, UINT nIDCaption)
: CPropertyPage(nIDTemplate, nIDCaption)
{
}
CResizablePage::CResizablePage(LPCTSTR lpszTemplateName, UINT nIDCaption)
: CPropertyPage(lpszTemplateName, nIDCaption)
{
}
CResizablePage::~CResizablePage()
{
}
BEGIN_MESSAGE_MAP(CResizablePage, CPropertyPage)
//{{AFX_MSG_MAP(CResizablePage)
ON_WM_SIZE()
ON_WM_ERASEBKGND()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CResizablePage message handlers
void CResizablePage::OnSize(UINT nType, int cx, int cy)
{
CWnd::OnSize(nType, cx, cy);
ArrangeLayout();
}
BOOL CResizablePage::OnEraseBkgnd(CDC* pDC)
{
// Windows XP doesn't like clipping regions ...try this!
EraseBackground(pDC);
return TRUE;
/* ClipChildren(pDC); // old-method (for safety)
return CPropertyPage::OnEraseBkgnd(pDC);
*/
}
|