📄 treeviewex.h
字号:
// TreeViewEx.h: interface for the CTreeViewHelper class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_TREEVIEWEX_H__D0740F56_5D48_4BF6_80D6_0BB16BDEDC31__INCLUDED_)
#define AFX_TREEVIEWEX_H__D0740F56_5D48_4BF6_80D6_0BB16BDEDC31__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
/////////////////////////////////////////////////////////////////////////////
// CTreeViewEx view
class CDirFileNode;
class CDirFileInfo;
class CTreeViewEx : public CTreeView
{
protected:
CTreeViewEx(); // protected constructor used by dynamic creation
DECLARE_DYNCREATE(CTreeViewEx)
// Attributes
public:
// Operations
public:
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CTreeViewEx)
public:
virtual void OnInitialUpdate();
protected:
virtual void OnDraw(CDC* pDC); // overridden to draw this view
virtual void PostNcDestroy();
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
//}}AFX_VIRTUAL
// Implementation
protected:
virtual ~CTreeViewEx();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
void FillTreeCtrl(CDirFileNode * pNode, HTREEITEM hParent = TVI_ROOT);
void RecursiveFillTree( CTreeCtrl &tc, CDirFileNode * pNode, HTREEITEM hParent );
void SetModifiedFlag( BOOL bModified = TRUE );
// Generated message map functions
protected:
//{{AFX_MSG(CTreeViewEx)
afx_msg void OnItemexpanded(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnKillFocus(CWnd* pNewWnd);
afx_msg void OnSetFocus(CWnd* pOldWnd);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
protected:
CDirFileInfo * m_pInfo;
CImageList * m_pImgLst;
CString m_strExt;
CString m_strPathName;
HTREEITEM m_hSelOnKilled;
HBITMAP m_hBmp;
static const int IMG_IDX;
static const int IMG_SEL_IDX;
static const int IMG_COLL_IDX;
static const int IMG_COLL_SEL_IDX;
static const int IMG_EXPA_IDX;
static const int IMG_EXPA_SEL_IDX;
private:
};
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_TREEVIEWEX_H__D0740F56_5D48_4BF6_80D6_0BB16BDEDC31__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -