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

📄 symbolpropertiesgeneralpage.h

📁 ResOrg 图形化管理Vc项目的资源ID的工具的源代码。 ResOrg - Manage and Renumber Resource Symbol IDs Introduction The
💻 H
字号:
/************************************************************************
 *
 *                 Resource ID Organiser Core Library
 *
 * (c) Copyright 2000-2004 by Anna-Jayne Metcalfe (resorg@annasplace.me.uk)
 *                         All rights reserved.
 *
 ************************************************************************
 *                                                                       
 *  Filename    : SymbolPropertiesGeneralPage.h
 *
 *  Description : CSymbolPropertiesGeneralPage - property page class
 *                
 *  Compiler    : Microsoft Visual C++ 6.0, Service Pack 3 or later
 *                Microsoft Visual C++ .NET 2002
 *                                                                       
 *  Target                                                               
 *  Environment : Windows 98/NT/2000/XP
 *
 *  NOTE:
 *
 *    This software is provided "as is" free for personal use. All
 *    title and copyrights in and to the software, including but not
 *    limited to any images, text, etc. incorporated into it, are
 *    owned by Anna-Jayne Metcalfe, except where acknowledged otherwise.
 *
 *    Your may freely to use this code in your own products, PROVIDED
 *    this notice is not removed or modified.
 *
 *
 *    Visit http://www.annasplace.me.uk/resorg for latest updates
 *
 ************************************************************************
 *
 *   MODIFICATION HISTORY:
 *
 *           This is a controlled document. See project configuration
 *           control tool for latest version and full version history.
 *
 *    $Archive: /Projects/AddIns/ResOrg/ResOrgCore/SymbolPropertiesGeneralPage.h $
 *   $Revision: 19 $
 *       $Date: 11/07/04 16:13 $
 *     $Author: Anna $
 *
 *    $History: SymbolPropertiesGeneralPage.h $
 * 
 * *****************  Version 19  *****************
 * User: Anna         Date: 11/07/04   Time: 16:13
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Added support for detection of out of range symbols
 * 
 * *****************  Version 18  *****************
 * User: Anna         Date: 15/04/03   Time: 19:14
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Removed unnecessary header file guards
 * 
 * *****************  Version 17  *****************
 * User: Anna         Date: 25/02/03   Time: 21:25
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Symbol conflict checking now handles inter-file conflicts better
 * 
 * *****************  Version 16  *****************
 * User: Anna         Date: 2/01/03    Time: 0:10
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Added a "File Name" control
 * 
 * *****************  Version 15  *****************
 * User: Anna         Date: 3/12/02    Time: 20:17
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Replaced the rich edit control with an HTML static control
 * 
 * *****************  Version 14  *****************
 * User: Anna         Date: 25/11/02   Time: 15:19
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Changed website address in banner
 * 
 * *****************  Version 13  *****************
 * User: Anna         Date: 22/10/02   Time: 13:24
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Changed name/mail address (at last!)
 * 
 * *****************  Version 12  *****************
 * User: Andy         Date: 7/06/02    Time: 17:04
 * Updated in $/Projects/AddIns/ResOrg/ResOrgCore
 * Renamed the ResOrgUtils module to ResOrgCore. Updated file banners
 * accordingly
 * 
 * *****************  Version 11  *****************
 * User: Andy         Date: 27/05/02   Time: 13:37
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * Knock on changes from CResourceSymbolBuffer (now
 * CResourceSymbolManager)
 * 
 * *****************  Version 10  *****************
 * User: Andy         Date: 12/27/01   Time: 10:39p
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * Added an option to allow editing of the value but not the name
 * 
 * *****************  Version 9  *****************
 * User: Andy         Date: 22/06/01   Time: 9:53
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * Made class declaration "Rose friendly"
 * 
 * *****************  Version 8  *****************
 * User: Andy         Date: 23/04/01   Time: 21:15
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * 1.  Added "Fix Conflict" button
 * 2.  A warning message is now displayed when a symbol is made read-only
 * 
 * *****************  Version 7  *****************
 * User: Andy         Date: 2/04/01    Time: 17:26
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * 1.  Added a rich edit control (and associated icon) to warn of symbol
 * name/value conflicts
 * 2.  Improved validation routines and messages
 * 
 * *****************  Version 6  *****************
 * User: Andy         Date: 27/03/01   Time: 15:22
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * 1.  Added validation of symbol names
 * 2.  When the symbol value changes, the parent property sheet is
 * notified to update the "Conflicts" page
 * 
 * *****************  Version 5  *****************
 * User: Andy         Date: 9/03/01    Time: 7:06
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * Make the warning prompt when a symbol name is changed optional, so it
 * can be disabled when the dialog is used to edit the properties of a
 * symbol being added
 * 
 * *****************  Version 4  *****************
 * User: Andy         Date: 17/02/01   Time: 7:05
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 * 1.  Converted to proeprty page
 * 2.  Added "type" icon
 * 3.  Added support for read only symbols
 * 4.  The "type" control is now set automatically when the symbol name is
 * changed
 * 
 * *****************  Version 3  *****************
 * User: Andy         Date: 29/11/00   Time: 18:38
 * Updated in $/Projects/AddIns/ResOrg/ResOrgUtils
 *  Added file banners
 *
 * $Nokeywords: $
 *
 ************************************************************************/

#pragma once


#include "ResourceSymbolManager.h"


/////////////////////////////////////////////////////////////////////////////
// CSymbolPropertiesGeneralPage property page

#define CSymbolPropertiesGeneralPage_BASE							CNGPropertyPage

class RESORGCORE_EXT_CLASS	CSymbolPropertiesGeneralPage : public	CNGPropertyPage
{
// Construction
public:
			CSymbolPropertiesGeneralPage(void);

	virtual	~CSymbolPropertiesGeneralPage(void);


// Data members
protected:
			enum { IDD = IDD_SYM_GENERAL_PAGE };

			CStatic					m_ctrlIcon;
			CStatic					m_ctrlWarningIcon;
			CNGHtmlStaticCtrl		m_ctrlWarning;
			CNGHtmlStaticCtrl		m_ctrlReadOnlyWarning;
			CString					m_sName;
			CString					m_sType;
			UINT					m_uIconID;
			UINT					m_uValue;
			CString					m_sFileName;
			BOOL					m_bEditValueOnly;
			BOOL					m_bReadOnly;
			CString					m_sSavedName;
			BOOL					m_bWarnOnSymbolChanges;

			CResourceSymbolManager*	m_pSymbols;
			CResourceSymbol*		m_pSymbol;

// Virtual Overrides
protected:
	virtual void					DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	virtual	BOOL					OnInitDialog(void);
	virtual	BOOL					OnKillActive(void);
	virtual	void					OnOK(void);


// Operations
public:
			bool					Initialise(	CResourceSymbolManager* pSymbols,
												CResourceSymbol* pSymbol,
                                                bool bEditValueOnly = false);

			void					DisableSymbolChangeWarnings(void);

			CString					GetName(void) const
										{ return m_sName; }

			UINT					GetValue(void) const
										{ return m_uValue; }

			BOOL					IsReadOnly(void) const
										{ return m_bReadOnly; }

// Implementation
protected:
			void					DDX_SymbolName(	CDataExchange* pDX,
													UINT uIDC,
													CString& rsSymbolName);

			void					DDV_SymbolName(	CDataExchange* pDX,
													CString& rsSymbolName);

			bool					IsNameUnique(	CResourceSymbol* pSymbol,
													const CString& sName,
													bool bCheckSameFileOnly) const;

			bool					IsValueUnique(	CResourceSymbol* pSymbol,
													UINT uValue,
													bool bCheckSameFileOnly) const;

			bool					SetTypeIcon(	UINT uIconID);

			bool					SetWarningText(	const CString& sWarning,
													LPCTSTR pszIconID = NULL);

			bool					AreSymbolsInSameFile(
													CResourceSymbol* pSymbol1,
													CResourceSymbol* pSymbol2) const;

			void					CheckNameAndValue(void);


// Message handlers
protected:
	afx_msg	void					OnCmdSymbolName(void);
	afx_msg	void					OnCmdSymbolValue(void);
	afx_msg	void					OnCmdReadOnly(void);
	afx_msg	void					OnClickedFixValue(void);

	DECLARE_MESSAGE_MAP()
};

⌨️ 快捷键说明

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