TestView.h
资源名称:treext.zip [点击查看]
上传用户:kesuntpe
上传日期:2007-01-02
资源大小:29k
文件大小:2k
源码类别:
TreeView控件
开发平台:
Visual C++
- // TestView.h : interface of the CTestView class
- //
- /////////////////////////////////////////////////////////////////////////////
- #if !defined(AFX_TESTVIEW_H__82366F2D_66CD_11D2_89CB_CB294B116A69__INCLUDED_)
- #define AFX_TESTVIEW_H__82366F2D_66CD_11D2_89CB_CB294B116A69__INCLUDED_
- #if _MSC_VER > 1000
- #pragma once
- #endif // _MSC_VER > 1000
- #include "TreeViewExt.h"
- class CTestView : public CTreeView, CTreeViewExt<int>
- {
- protected: // create from serialization only
- CTestView();
- DECLARE_DYNCREATE(CTestView)
- // Attributes
- public:
- CTestDoc* GetDocument();
- // Operations
- public:
- // Overrides
- // ClassWizard generated virtual function overrides
- //{{AFX_VIRTUAL(CTestView)
- public:
- virtual void OnDraw(CDC* pDC); // overridden to draw this view
- virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
- protected:
- virtual void OnInitialUpdate(); // called first time after construct
- virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
- virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
- virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
- //}}AFX_VIRTUAL
- // Implementation
- public:
- virtual ~CTestView();
- #ifdef _DEBUG
- virtual void AssertValid() const;
- virtual void Dump(CDumpContext& dc) const;
- #endif
- protected:
- // Generated message map functions
- protected:
- //{{AFX_MSG(CTestView)
- // NOTE - the ClassWizard will add and remove member functions here.
- // DO NOT EDIT what you see in these blocks of generated code !
- //}}AFX_MSG
- afx_msg LONG OnDataAvailable(WPARAM wParam, LPARAM lParam);
- // CTreeViewExt overrides
- public:
- CTreeCtrl& GetTreeCtrl() const { return CTreeView::GetTreeCtrl(); }
- virtual void GetRootItems(list<TreeData>& List);
- virtual void GetChildItems(list<TreeData>::iterator it, list<TreeData>& List);
- DECLARE_MESSAGE_MAP()
- };
- #ifndef _DEBUG // debug version in TestView.cpp
- inline CTestDoc* CTestView::GetDocument()
- { return (CTestDoc*)m_pDocument; }
- #endif
- /////////////////////////////////////////////////////////////////////////////
- //{{AFX_INSERT_LOCATION}}
- // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
- #endif // !defined(AFX_TESTVIEW_H__82366F2D_66CD_11D2_89CB_CB294B116A69__INCLUDED_)