home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / mfc / ole / oleview / iviewers / tlbtree.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-03-27  |  2.3 KB  |  80 lines

  1. // tlbtree.h : header file
  2. //
  3.  
  4. // This is a part of the Microsoft Foundation Classes C++ library.
  5. // Copyright (C) 1992-1998 Microsoft Corporation
  6. // All rights reserved.
  7. //
  8. // This source code is only intended as a supplement to the
  9. // Microsoft Foundation Classes Reference and related
  10. // electronic documentation provided with the library.
  11. // See these sources for detailed information regarding the
  12. // Microsoft Foundation Classes product.
  13.  
  14. #ifndef __TLBTREE_H__
  15. #define __TLBTREE_H__
  16.  
  17. #include "tree.h"
  18.  
  19. /////////////////////////////////////////////////////////////////////////////
  20. // CTypeLibTreeView view
  21. #define ID_TREEVIEW 42
  22. class CTypeLibTreeView : public CView
  23. {
  24. friend class CTypeLibWnd ;
  25. public:
  26.     CTypeLibTreeView();           // protected constructor used by dynamic creation
  27.     virtual ~CTypeLibTreeView();
  28.     DECLARE_DYNCREATE(CTypeLibTreeView)
  29.  
  30. // Attributes
  31. public:
  32.     CTreeCtrl       m_tree ;
  33.  
  34.     ITypeLib*       m_ptlb ;
  35.  
  36.     enum {IMGID_TYPELIB = 0,
  37.           IMGID_TYPEINFO_C,
  38.           IMGID_TYPEINFO_O };
  39.     CImageList      m_images ;
  40.     HTREEITEM       m_hTypeInfos ;
  41.  
  42. // Operations
  43. public:
  44.     void DeleteTreeItems( HTREEITEM htree ) ;
  45.  
  46. // Overrides
  47.     // ClassWizard generated virtual function overrides
  48.     //{{AFX_VIRTUAL(CTypeLibTreeView)
  49.     public:
  50.     virtual void OnInitialUpdate();
  51.     protected:
  52.     virtual void OnDraw(CDC* pDC);
  53.     virtual void OnUpdate(CView* pSender, LPARAM lHint, CObject* pHint);
  54.     //}}AFX_VIRTUAL
  55.  
  56. // Implementation
  57. protected:
  58. #ifdef _DEBUG
  59.     virtual void AssertValid() const;
  60.     virtual void Dump(CDumpContext& dc) const;
  61. #endif
  62.  
  63.     // Generated message map functions
  64. protected:
  65.     //{{AFX_MSG(CTypeLibTreeView)
  66.     afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
  67.     afx_msg void OnDestroy();
  68.     afx_msg void OnSize(UINT nType, int cx, int cy);
  69.     //}}AFX_MSG
  70.     afx_msg void OnTreeSelchanged(NMHDR* pNMHDR, LRESULT* pResult) ;
  71.     afx_msg void OnTreeItemExpanding(NMHDR* pNMHDR, LRESULT* pResult) ;
  72.     afx_msg void OnTreeItemExpanded(NMHDR* pNMHDR, LRESULT* pResult) ;
  73.     afx_msg void OnTreeItemReturn(NMHDR* pNMHDR, LRESULT* pResult) ;
  74.     afx_msg void OnTreeDeleteItem(NMHDR* pNMHDR, LRESULT* pResult) ;
  75.     DECLARE_MESSAGE_MAP()
  76. };
  77. #endif // __TLBTREE_H__
  78.  
  79. /////////////////////////////////////////////////////////////////////////////
  80.