Merge pull request #1551 from DOCGroup/plm_jira_333
[ACE_TAO.git] / TAO / examples / mfc / serverView.cpp
blobd5c50850b4c660c57e4bdf2dc3e861500917a01b
1 // serverView.cpp : implementation of the CServerView class
3 #include "stdafx.h"
4 #include "server.h"
6 #include "serverDoc.h"
7 #include "serverView.h"
9 #ifdef _DEBUG
10 #define new DEBUG_NEW
11 #undef THIS_FILE
12 static char THIS_FILE[] = __FILE__;
13 #endif
15 /////////////////////////////////////////////////////////////////////////////
16 // CServerView
18 IMPLEMENT_DYNCREATE(CServerView, CView)
20 BEGIN_MESSAGE_MAP(CServerView, CView)
21 //{{AFX_MSG_MAP(CServerView)
22 // NOTE - the ClassWizard will add and remove mapping macros here.
23 // DO NOT EDIT what you see in these blocks of generated code!
24 //}}AFX_MSG_MAP
25 // Standard printing commands
26 ON_COMMAND(ID_FILE_PRINT, CView::OnFilePrint)
27 ON_COMMAND(ID_FILE_PRINT_DIRECT, CView::OnFilePrint)
28 ON_COMMAND(ID_FILE_PRINT_PREVIEW, CView::OnFilePrintPreview)
29 END_MESSAGE_MAP()
31 /////////////////////////////////////////////////////////////////////////////
32 // CServerView construction/destruction
34 CServerView::CServerView()
36 // TODO: add construction code here
39 CServerView::~CServerView()
43 BOOL CServerView::PreCreateWindow(CREATESTRUCT& cs)
45 // TODO: Modify the Window class or styles here by modifying
46 // the CREATESTRUCT cs
48 return CView::PreCreateWindow(cs);
51 /////////////////////////////////////////////////////////////////////////////
52 // CServerView drawing
54 void CServerView::OnDraw(CDC* pDC)
56 CServerDoc* pDoc = GetDocument();
57 ASSERT_VALID(pDoc);
58 // TODO: add draw code for native data here
61 /////////////////////////////////////////////////////////////////////////////
62 // CServerView printing
64 BOOL CServerView::OnPreparePrinting(CPrintInfo* pInfo)
66 // default preparation
67 return DoPreparePrinting(pInfo);
70 void CServerView::OnBeginPrinting(CDC* /*pDC*/, CPrintInfo* /*pInfo*/)
72 // TODO: add extra initialization before printing
75 void CServerView::OnEndPrinting(CDC* /*pDC*/, CPrintInfo* /*pInfo*/)
77 // TODO: add cleanup after printing
80 /////////////////////////////////////////////////////////////////////////////
81 // CServerView diagnostics
83 #ifdef _DEBUG
84 void CServerView::AssertValid() const
86 CView::AssertValid();
89 void CServerView::Dump(CDumpContext& dc) const
91 CView::Dump(dc);
94 CServerDoc* CServerView::GetDocument() // non-debug version is inline
96 ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(CServerDoc)));
97 return (CServerDoc*)m_pDocument;
99 #endif //_DEBUG
101 /////////////////////////////////////////////////////////////////////////////
102 // CServerView message handlers