home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 January / Chip_2001-01_cd1.bin / tema / mysql / mysql-3.23.28g-win-source.exe / mysqlmanager / mysqlmanagerview.h < prev    next >
C/C++ Source or Header  |  1999-10-12  |  3KB  |  90 lines

  1. // MySqlManagerView.h : interface of the CMySqlManagerView class
  2. //
  3. /////////////////////////////////////////////////////////////////////////////
  4.  
  5. #if !defined(AFX_MYSQLMANAGERVIEW_H__826CB2F4_8B6D_11D1_AEC1_00600806E071__INCLUDED_)
  6. #define AFX_MYSQLMANAGERVIEW_H__826CB2F4_8B6D_11D1_AEC1_00600806E071__INCLUDED_
  7.  
  8. #if _MSC_VER >= 1000
  9. #pragma once
  10. #endif // _MSC_VER >= 1000
  11.  
  12. #include <afxcview.h>
  13. #include "cresource.h"
  14.  
  15. class CToolSql;
  16.  
  17. class CMySqlManagerView : public CTreeView
  18. {
  19. protected: // create from serialization only
  20.     CMySqlManagerView();
  21.     DECLARE_DYNCREATE(CMySqlManagerView)
  22.  
  23. // Attributes
  24. public:
  25.     CMySqlManagerDoc* GetDocument();
  26.  
  27. // Operations
  28. public:
  29.  
  30. // Overrides
  31.     // ClassWizard generated virtual function overrides
  32.     //{{AFX_VIRTUAL(CMySqlManagerView)
  33.     public:
  34.     virtual void OnDraw(CDC* pDC);  // overridden to draw this view
  35.     virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
  36.     virtual void OnInitialUpdate();
  37.     virtual BOOL PreTranslateMessage(MSG* pMsg);
  38.     protected:
  39.     virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
  40.     virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
  41.     virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
  42.     //}}AFX_VIRTUAL
  43.  
  44. // Implementation
  45.  
  46.    CResource*        GetSelectedResource(HTREEITEM* phItemRet=NULL);
  47.    CResourceServer*  GetServerResource(HTREEITEM hItem);
  48.  
  49.    HTREEITEM   AddResource ( HTREEITEM hParent, CResource* pRes, HTREEITEM hLastItem = TVI_FIRST ) ;
  50.    void        ProcessResultSet ( HTREEITEM hItem, LPVOID result, CResource* pResource );
  51.  
  52. public:
  53.     virtual ~CMySqlManagerView();
  54. #ifdef _DEBUG
  55.     virtual void AssertValid() const;
  56.     virtual void Dump(CDumpContext& dc) const;
  57. #endif
  58.  
  59. protected:
  60.  
  61.     CTreeCtrl*       m_pTree;
  62.     CImageList*       m_pImages;
  63.     CBitmap*          m_pbmBmp;
  64.     CToolSql*      m_pTool;
  65.  
  66. // Generated message map functions
  67. protected:
  68.     //{{AFX_MSG(CMySqlManagerView)
  69.     afx_msg void OnDblclk(NMHDR* pNMHDR, LRESULT* pResult);
  70.     afx_msg void OnSqlToolQuery();
  71.     afx_msg void OnRefresh();
  72.     afx_msg void OnRegisterServer();
  73.    afx_msg void OnServerProperties();
  74.     afx_msg void OnRclick(NMHDR* pNMHDR, LRESULT* pResult);
  75.     //}}AFX_MSG
  76.     DECLARE_MESSAGE_MAP()
  77. };
  78.  
  79. #ifndef _DEBUG  // debug version in MySqlManagerView.cpp
  80. inline CMySqlManagerDoc* CMySqlManagerView::GetDocument()
  81.    { return (CMySqlManagerDoc*)m_pDocument; }
  82. #endif
  83.  
  84. /////////////////////////////////////////////////////////////////////////////
  85.  
  86. //{{AFX_INSERT_LOCATION}}
  87. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  88.  
  89. #endif // !defined(AFX_MYSQLMANAGERVIEW_H__826CB2F4_8B6D_11D1_AEC1_00600806E071__INCLUDED_)
  90.