home *** CD-ROM | disk | FTP | other *** search
- // DoServerView.cpp : implementation of the CDoServerView class
- //
-
- #include "stdafx.h"
- #include "DoServer.h"
-
- #include "DoServerDoc.h"
- #include "DoServerView.h"
-
- #ifdef _DEBUG
- #define new DEBUG_NEW
- #undef THIS_FILE
- static char THIS_FILE[] = __FILE__;
- #endif
-
- /////////////////////////////////////////////////////////////////////////////
- // CDoServerView
-
- IMPLEMENT_DYNCREATE(CDoServerView, CView)
-
- BEGIN_MESSAGE_MAP(CDoServerView, CView)
- //{{AFX_MSG_MAP(CDoServerView)
- // NOTE - the ClassWizard will add and remove mapping macros here.
- // DO NOT EDIT what you see in these blocks of generated code!
- ON_COMMAND(ID_CANCEL_EDIT_SRVR, OnCancelEditSrvr)
- //}}AFX_MSG_MAP
- // Standard printing commands
- ON_COMMAND(ID_FILE_PRINT, CView::OnFilePrint)
- ON_COMMAND(ID_FILE_PRINT_DIRECT, CView::OnFilePrint)
- ON_COMMAND(ID_FILE_PRINT_PREVIEW, CView::OnFilePrintPreview)
- END_MESSAGE_MAP()
-
- /////////////////////////////////////////////////////////////////////////////
- // CDoServerView construction/destruction
-
- CDoServerView::CDoServerView()
- {
- // TODO: add construction code here
-
- }
-
- CDoServerView::~CDoServerView()
- {
- }
-
- BOOL CDoServerView::PreCreateWindow(CREATESTRUCT& cs)
- {
- // TODO: Modify the Window class or styles here by modifying
- // the CREATESTRUCT cs
-
- return CView::PreCreateWindow(cs);
- }
-
- /////////////////////////////////////////////////////////////////////////////
- // CDoServerView drawing
-
- void CDoServerView::OnDraw(CDC* pDC)
- {
- CDoServerDoc* pDoc = GetDocument();
- ASSERT_VALID(pDoc);
-
- // TODO: add draw code for native data here
- pDoc->Draw(pDC); // OLE server addition
- }
-
- /////////////////////////////////////////////////////////////////////////////
- // CDoServerView printing
-
- BOOL CDoServerView::OnPreparePrinting(CPrintInfo* pInfo)
- {
- // default preparation
- return DoPreparePrinting(pInfo);
- }
-
- void CDoServerView::OnBeginPrinting(CDC* /*pDC*/, CPrintInfo* /*pInfo*/)
- {
- // TODO: add extra initialization before printing
- }
-
- void CDoServerView::OnEndPrinting(CDC* /*pDC*/, CPrintInfo* /*pInfo*/)
- {
- // TODO: add cleanup after printing
- }
-
- /////////////////////////////////////////////////////////////////////////////
- // OLE Server support
-
- // The following command handler provides the standard keyboard
- // user interface to cancel an in-place editing session. Here,
- // the server (not the container) causes the deactivation.
- void CDoServerView::OnCancelEditSrvr()
- {
- GetDocument()->OnDeactivateUI(FALSE);
- }
-
- /////////////////////////////////////////////////////////////////////////////
- // CDoServerView diagnostics
-
- #ifdef _DEBUG
- void CDoServerView::AssertValid() const
- {
- CView::AssertValid();
- }
-
- void CDoServerView::Dump(CDumpContext& dc) const
- {
- CView::Dump(dc);
- }
-
- CDoServerDoc* CDoServerView::GetDocument() // non-debug version is inline
- {
- ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(CDoServerDoc)));
- return (CDoServerDoc*)m_pDocument;
- }
- #endif //_DEBUG
-
- /////////////////////////////////////////////////////////////////////////////
- // CDoServerView message handlers
-