⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 customizepropsheet.h

📁 用bcg库编写的java IDE 源码
💻 H
字号:

#ifndef __CBCGTOOLBARCUSTOMIZE_H__
#define __CBCGTOOLBARCUSTOMIZE_H__

#include "bcgcontrolbar.h"
#include "BCGCustomizeCommandsPage.h"
#include "BCGCustomizeToolbarsPage.h"
#include "BCGCustomizeKeyboardPage.h"
#include "BCGCustomizeToolsPage.h"

#include "CBCGToolbarCustomizePages.h"


class CBCGToolBarImages;
class CBCGToolbarButton;
class CBCGToolBar;
/////////////////////////////////////////////////////////////////////////////
// CCustomizePropSheet

class BCGCONTROLBARDLLEXPORT CCustomizePropSheet : public CPropertySheet
{
	DECLARE_DYNAMIC(CCustomizePropSheet)

// Construction
public:
	CCustomizePropSheet (CFrameWnd* pWndParentFrame, 
							BOOL bAutoSetFromMenus = FALSE,
							UINT uiFlags = 0xFFFF,
							CList<CRuntimeClass*,CRuntimeClass*>* m_plistCustomPages = NULL);// Attributes
public:
	UINT GetFlags () const
	{
		return m_uiFlags;
	}

protected:
	//------------------------------------------
	// Toolbar+menu items divided by categories:
	//------------------------------------------
	CMap<CString, LPCTSTR, CObList*, CObList*>	m_ButtonsByCategory;
	CStringList									m_strCategoriesList;
													// Need for order!
	//----------------
	// Property pages:
	//----------------	
	CBCGCustomizeCommandsPage*	m_pCommandsPage;
	CBCGCustomizeToolbarsPage*	m_pToolbarsPage;
	CBCGCustomizeKeyboardPage*	m_pKeyboardPage;
	CBCGCustomizeToolsPage*		m_pMenuPage;
	//CBCGMousePage*		m_pMousePage;
	//CBCGOptionsPage*	m_pOptionsPage;
	
	// ET: Support for additional custom pages
	CList<CPropertyPage*,CPropertyPage*>	m_listCustomPages;

	CString			m_strAllCommands;

	CFrameWnd*			m_pParentFrame;
	BOOL				m_bAutoSetFromMenus;
	UINT				m_uiFlags;

// Operations
public:

	void AddButton (UINT uiCategoryId, const CBCGToolbarButton& button,
					int iInsertAfter = -1);
	void AddButton (LPCTSTR lpszCategory, const CBCGToolbarButton& button,
					int iInsertAfter = -1);

	int RemoveButton (UINT uiCategoryId, UINT uiCmdId);
	int RemoveButton (LPCTSTR lpszCategory, UINT uiCmdId);

	void ReplaceButton (UINT uiCmd, const CBCGToolbarButton& button);

	BOOL AddToolBar (UINT uiCategoryId, UINT uiToolbarResId);
	BOOL AddToolBar (LPCTSTR lpszCategory, UINT uiToolbarResId);
	BOOL AddMenu (UINT uiMenuResId);
	void AddMenuCommands (const CMenu* pMenu, BOOL bPopup, LPCTSTR lpszCategory = NULL);

	BOOL RenameCategory(LPCTSTR lpszCategoryOld, LPCTSTR lpszCategoryNew);

	BOOL SetUserCategory (LPCTSTR lpszCategory);

	void EnableUserDefinedToolbars (BOOL bEnable = TRUE);

	void FiilCategotiesComboBox (CComboBox& wndCategory) const;
	void FiilCategotiesListBox (CListBox& wndCategory) const;
	void FillAllCommandsList (CListBox& wndListOfCommands) const;

	LPCTSTR GetCommandName (UINT uiCmd) const;

protected:
	void SetFrameCustMode (BOOL bCustMode);
	void ShowToolBar (CBCGToolBar* pToolBar, BOOL bShow);
	void SetupFromMenus ();

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CBCGToolbarCustomize)
	public:
	virtual BOOL OnInitDialog();
	protected:
	virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
	//}}AFX_VIRTUAL

public:
	virtual BOOL Create();

// Implementation
public:
	 virtual ~CCustomizePropSheet();
	 virtual void PostNcDestroy();

// Generated message map functions
protected:
	//{{AFX_MSG(CBCGToolbarCustomize)
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	afx_msg BOOL OnHelpInfo(HELPINFO* pHelpInfo);
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()

// Attributes:
protected:
};

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_CUSTOMIZEPROPSHEET_H__89689B27_C70C_460B_AB1C_041CE7CBC30E__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -