// OpenGraphMFCClientView.h : interface of the COpenGraphMFCClientView class
//


#pragma once

// jxu--
#include "OpenGraph.h"
using namespace NSOpenGraphLib;


class COpenGraphMFCClientView : public CView
{
protected: // create from serialization only
	COpenGraphMFCClientView();
	DECLARE_DYNCREATE(COpenGraphMFCClientView)

// Attributes
public:
	COpenGraphMFCClientDoc* GetDocument() const;

// Operations
public:

// Overrides
public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
protected:
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);

// Implementation
public:
	virtual ~COpenGraphMFCClientView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

    // jxu
protected:
    COpenGraph m_openGraph;
    int m_nCx;
    int m_nCy;

// Generated message map functions
protected:
	DECLARE_MESSAGE_MAP()
public:
    afx_msg void OnViewSelectall();
    afx_msg void OnViewUnselectall();
    afx_msg void OnViewReverseselect();
    afx_msg void OnViewShowselected();
    afx_msg void OnViewViewfront();
    afx_msg void OnViewViewisometric();
    afx_msg void OnViewResetview();
    afx_msg void OnViewProjectpoint();
    afx_msg void OnDrawDrawnodes();
    afx_msg void OnDrawDrawlines();
    afx_msg void OnDrawDrawtriangles();
    afx_msg void OnDrawDrawquads();
    afx_msg void OnDrawDrawwindownodes();
    afx_msg void OnDrawDrawwindowlines();
    afx_msg void OnDrawDrawwindowtriangles();
    afx_msg void OnDrawDrawwindowquads();
    afx_msg void OnDrawClear();
    afx_msg void OnDrawSaveimage();
    afx_msg void OnModeDefault();
    afx_msg void OnModeTrack();
    afx_msg void OnModeSelect();
    afx_msg void OnModePan();
    afx_msg void OnModeRotate();
    afx_msg void OnModeWindowzoom();
    afx_msg void OnModePixelpan();
    afx_msg BOOL OnEraseBkgnd(CDC* pDC);
    afx_msg void OnSize(UINT nType, int cx, int cy);
    afx_msg BOOL OnMouseWheel(UINT nFlags, short zDelta, CPoint pt);
    afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
    afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message);
    afx_msg void OnPaint();
    afx_msg void OnMouseMove(UINT nFlags, CPoint point);
    afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
};

#ifndef _DEBUG  // debug version in OpenGraphMFCClientView.cpp
inline COpenGraphMFCClientDoc* COpenGraphMFCClientView::GetDocument() const
   { return reinterpret_cast<COpenGraphMFCClientDoc*>(m_pDocument); }
#endif

