-
Notifications
You must be signed in to change notification settings - Fork 0
/
ComponentPlacementRestrictionAreaSheet.cpp
58 lines (45 loc) · 1.87 KB
/
ComponentPlacementRestrictionAreaSheet.cpp
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
// ComponentPlacementRestrictionAreaSheet.cpp : implementation file
//
#include "stdafx.h"
#include "AP210Viewer.h"
#include "ComponentPlacementRestrictionAreaSheet.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CComponentPlacementRestrictionAreaSheet
IMPLEMENT_DYNAMIC(CComponentPlacementRestrictionAreaSheet, CPropertySheet)
CComponentPlacementRestrictionAreaSheet::CComponentPlacementRestrictionAreaSheet(UINT nIDCaption, CWnd* pParentWnd, UINT iSelectPage)
:CPropertySheet(nIDCaption, pParentWnd, iSelectPage) {
// MountingRestrictionArea page
AddPage(&m_mraPage);
// ComponentRestrictionAssignment page
AddPage(&m_craPage);
}
CComponentPlacementRestrictionAreaSheet::CComponentPlacementRestrictionAreaSheet(LPCTSTR pszCaption, CWnd* pParentWnd, UINT iSelectPage)
:CPropertySheet(pszCaption, pParentWnd, iSelectPage) {
// MountingRestrictionArea page
AddPage(&m_mraPage);
// ComponentRestrictionAssignment page
AddPage(&m_craPage);
}
CComponentPlacementRestrictionAreaSheet::~CComponentPlacementRestrictionAreaSheet()
{
}
BEGIN_MESSAGE_MAP(CComponentPlacementRestrictionAreaSheet, CPropertySheet)
//{{AFX_MSG_MAP(CComponentPlacementRestrictionAreaSheet)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CComponentPlacementRestrictionAreaSheet message handlers
void CComponentPlacementRestrictionAreaSheet::setValues(PWBDataBase *PWB, MountingRestrictionArea *mra) {
Database = PWB;
m_mraPage.setValues(PWB->AP210Model, mra);
m_craPage.setValues(PWB, mra);
}
void CComponentPlacementRestrictionAreaSheet::setReadOnly(BOOL mode) {
m_mraPage.setReadOnly(mode);
m_craPage.setReadOnly(mode);
}