X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/275bf4c13ab7f4b041b0d5c78cfdece709800d14..1280032d6cb73a9c48fad0ecc23fbba92134fb42:/include/wx/config.h?ds=sidebyside diff --git a/include/wx/config.h b/include/wx/config.h index c48ee1c367..6f1adce1c8 100644 --- a/include/wx/config.h +++ b/include/wx/config.h @@ -11,8 +11,8 @@ // Licence: wxWindows license /////////////////////////////////////////////////////////////////////////////// -#ifndef _wxCONFIG_H -#define _wxCONFIG_H +#ifndef _WX_CONFIG_H_ +#define _WX_CONFIG_H_ #ifdef __GNUG__ #pragma interface "config.h" @@ -101,7 +101,7 @@ public: // ctor & virtual dtor // environment variable expansion is on by default - wxConfigBase() { m_bExpandEnvVars = TRUE; } + wxConfigBase() { m_bExpandEnvVars = TRUE; m_bRecordDefaults = FALSE; } // empty but ensures that dtor of all derived classes is virtual virtual ~wxConfigBase() { } @@ -172,7 +172,10 @@ public: // (this option is on by default, you can turn it on/off at any time) bool IsExpandingEnvVars() const { return m_bExpandEnvVars; } void SetExpandEnvVars(bool bDoIt = TRUE) { m_bExpandEnvVars = bDoIt; } - // does expansion only if needed + // recording of default values + void SetRecordDefaults(bool bDoIt = TRUE) { m_bRecordDefaults = bDoIt; } + bool IsRecordingDefaults() const { return m_bRecordDefaults; } + // does expansion only if needed wxString ExpandEnvVars(const wxString& str) const { wxString tmp; // Required for BC++ @@ -211,7 +214,9 @@ protected: private: // are we doing automatic environment variable expansion? bool m_bExpandEnvVars; - + // do we record default values? + bool m_bRecordDefaults; + // static variables static wxConfigBase *ms_pConfig; static bool ms_bAutoCreate; @@ -232,5 +237,5 @@ private: #define wxConfig wxFileConfig #endif -#endif //_wxCONFIG_H +#endif // _WX_CONFIG_H_