mrucombobox.h
来自「《突破Visual C++.NET编程实例五十讲+源文件,初学者学习的好东东!」· C头文件 代码 · 共 58 行
H
58 行
#pragma once
#include "afxpriv.h"
// CMRUComboBox
class CMRUComboBox : public CComboBox
{
DECLARE_DYNAMIC(CMRUComboBox)
public:
CMRUComboBox();
virtual ~CMRUComboBox();
protected:
CRecentFileList* m_pMRU;
CString m_cstrRegKey;
CString m_cstrRegValueFormat;
int m_nMaxMRUSize;
BOOL m_bSaveOnDestroy;
BOOL m_bSaveAfterAdd;
BOOL m_bRefreshAfterAdd;
// Operations
public:
BOOL AddToMRU ( LPCTSTR szNewItem );
void EmptyMRU();
void RefreshCtrl();
BOOL LoadMRU();
BOOL SaveMRU();
protected:
BOOL AllocNewMRU();
BOOL VerifyMRUParams() const;
BOOL m_bParamsChanged;
protected:
DECLARE_MESSAGE_MAP()
// Attributes & accessor functions
public:
void SetMRURegKey ( LPCTSTR szRegKey );
const CString& GetMRURegKey() const;
BOOL SetMRUValueFormat ( LPCTSTR szValueFormat );
const CString& GetMRUValueFormat() const;
int SetMaxMRUSize ( int nMaxSize );
int GetMaxMRUSize() const;
BOOL SetAutoSaveOnDestroy ( BOOL bAutoSave );
BOOL SetAutoSaveAfterAdd ( BOOL bAutoSave );
BOOL SetAutoRefreshAfterAdd ( BOOL bAutoRefresh );
};
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?