📄 fileopendlg.h
字号:
#if !defined(AFX_FILEOPENDLG_H__04B959E8_3973_45C5_BC62_E7BDB26B0B48__INCLUDED_)
#define AFX_FILEOPENDLG_H__04B959E8_3973_45C5_BC62_E7BDB26B0B48__INCLUDED_
#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000
// FileOpenDlg.h : header file
//
#include "ExDialog.h"
/////////////////////////////////////////////////////////////////////////////
// CFileOpenDlg dialog
class CFileOpenDlg : public CExDialog
{
// Construction
public:
CFileOpenDlg(CWnd* pParent = NULL); // standard constructor
// Dialog Data
//{{AFX_DATA(CFileOpenDlg)
enum { IDD = IDD_FILE_OPEN };
CButton m_btnOK;
CListCtrl m_listFile;
CTreeCtrl m_treeFolder;
//}}AFX_DATA
LPCTSTR GetFileName() {return m_strFile;}
LPCTSTR GetPath() {return m_strPath;}
void SetFilter(LPCTSTR pszFilter) {m_strFilter = pszFilter;}
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CFileOpenDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
CImageList m_imlTree,
m_imlList;
CString m_strPath,
m_strFile,
m_strFilter,
m_strDateFormat;
void EnumDirs(LPCTSTR pszPath, LPCTSTR pszFilter, HTREEITEM hItemParent);
void EnumFiles(LPCTSTR pszPath, LPCTSTR pszFilter);
CString GetFullPath(HTREEITEM hItem);
CString FormatSize(DWORD dwSize);
// Generated message map functions
//{{AFX_MSG(CFileOpenDlg)
virtual void OnOK();
virtual void OnCancel();
virtual BOOL OnInitDialog();
afx_msg void OnClickFolderTree(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnSelchangedFolderTree(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnClickFileList(NMHDR* pNMHDR, LRESULT* pResult);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_FILEOPENDLG_H__04B959E8_3973_45C5_BC62_E7BDB26B0B48__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -