]>
Commit | Line | Data |
---|---|---|
1 | // GeometryView.cpp : implementation of the CGeometryView class | |
2 | // | |
3 | ||
4 | #include "stdafx.h" | |
5 | #include "GeometryApp.h" | |
6 | ||
7 | #include <GeometryApp.h> | |
8 | #include "GeometryDoc.h" | |
9 | #include "GeometryView.h" | |
10 | ||
11 | #define ValZWMin 1 | |
12 | ||
13 | #ifdef _DEBUG | |
14 | #undef THIS_FILE | |
15 | static char THIS_FILE[] = __FILE__; | |
16 | #endif | |
17 | ||
18 | ///////////////////////////////////////////////////////////////////////////// | |
19 | // CGeometryView | |
20 | ||
21 | IMPLEMENT_DYNCREATE(CGeometryView, OCC_3dView) | |
22 | ||
23 | BEGIN_MESSAGE_MAP(CGeometryView, OCC_3dView) | |
24 | //{{AFX_MSG_MAP(CGeometryView) | |
25 | ON_COMMAND(ID_FILE_EXPORT_IMAGE, OnFileExportImage) | |
26 | //}}AFX_MSG_MAP | |
27 | END_MESSAGE_MAP() | |
28 | ||
29 | ///////////////////////////////////////////////////////////////////////////// | |
30 | // CGeometryView construction/destruction | |
31 | ||
32 | CGeometryView::CGeometryView() | |
33 | { | |
34 | } | |
35 | ||
36 | CGeometryView::~CGeometryView() | |
37 | { | |
38 | } | |
39 | ||
40 | ///////////////////////////////////////////////////////////////////////////// | |
41 | // CGeometryView diagnostics | |
42 | ||
43 | #ifdef _DEBUG | |
44 | void CGeometryView::AssertValid() const | |
45 | { | |
46 | CView::AssertValid(); | |
47 | } | |
48 | ||
49 | void CGeometryView::Dump(CDumpContext& dc) const | |
50 | { | |
51 | CView::Dump(dc); | |
52 | } | |
53 | ||
54 | CGeometryDoc* CGeometryView::GetDocument() // non-debug version is inline | |
55 | { | |
56 | ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(CGeometryDoc))); | |
57 | return (CGeometryDoc*)m_pDocument; | |
58 | } | |
59 | #endif //_DEBUG | |
60 | ||
61 | ///////////////////////////////////////////////////////////////////////////// | |
62 | // CGeometryView message handlers | |
63 | ||
64 | void CGeometryView::OnFileExportImage() | |
65 | { | |
66 | GetDocument()->ExportView (myView); | |
67 | } |