![]() |
VR-Forces 4.3 Class Documentation
|
Base class for shared settings managers. More...

Public Member Functions | |
| DtBaseSharedSettingsManager (DtDe &de, const std::string &name, const std::string &displayName, const std::string &ext) | |
| CTOR. | |
| virtual | ~DtBaseSharedSettingsManager () |
| Virtual DTOR. | |
Setting Persistence Methods | |
| virtual void | initializeBackup () |
| Creates a backup of the settings' current state. | |
| virtual void | setFromRecord (const RecordType &record) |
| Set the current settings' state from the given record. | |
| virtual void | getRecord (RecordType &record) const |
| Store the current settings' state in the given record. | |
Public Member Functions inherited from makVrv::DtCommonBaseSettingsManager< RecordType > | |
| DtCommonBaseSettingsManager (DtDe &de, const std::string &name, const std::string &displayName, const std::string &ext) | |
| CTOR The name, displayName, and extension parameters are used for creating the settings object (DtDeSettings) and backup, and for constructing the filename when readin/writing the records to disk. | |
| virtual | ~DtCommonBaseSettingsManager () |
| Virtual DTOR. | |
| virtual void | autoSaveIfNecessary () |
| Saves the current settings as defaults if autosave is enabled. | |
| virtual void | setAutoSave (bool doit) |
| Sets whether autosave is enabled for the settings manager. | |
| virtual bool | autoSave () const |
| Gets whether autosave is enabled for the settings manager. | |
| virtual void | setUseDefaultSettingsRecord (bool useit) |
| Sets whether setting initialization should check for a default record. | |
| virtual bool | useDefaultSettingsRecord () const |
| Gets whether setting initialization should check for a default record. | |
| virtual DtDeSettings * | settings () |
| Accessor for the manager's DtDeSettings object. | |
| virtual const DtDeSettings * | settings () const |
| Accessor for the manager's DtDeSettings object (const). | |
| virtual DtSettingsBackup * | settingsBackup () |
| Accessor for the manager's settings backup. | |
| virtual const DtSettingsBackup * | settingsBackup () const |
| Accessor for the manager's settings backup (const). | |
| virtual void | loadDefaults () |
| Initializes the settings and creates a backup. | |
| virtual void | saveDefaultSettings () |
| Saves the current settings' state as the default (on disk). | |
| virtual void | loadDefaultSettings (bool loadOnlyFactorySettings) |
| Loads the default settings from disk. | |
| virtual void | importSettings (const std::string &filePath) |
| Load the settings' state from the given file. | |
| virtual void | exportSettings (const std::string &filePath) const |
| Save the current settings' state to the given file. | |
Public Member Functions inherited from makVrv::DtVirtualBaseClass | |
| DtVirtualBaseClass () | |
| Do nothing constructor. | |
| virtual | ~DtVirtualBaseClass () |
| Virtual do nothing destructor. | |
Protected Types | |
| typedef DtSharedRecordSettingsBackup < SettingsType, RecordType > | SharedRecordBackupType |
Additional Inherited Members | |
Protected Attributes inherited from makVrv::DtCommonBaseSettingsManager< RecordType > | |
| DtSignalConnectionManager | myConnections |
| std::string | myName |
| std::string | myExtension |
| std::string | myDisplayName |
| bool | myUseDefaultSettingsRecordFlag |
| bool | myAutoSaveFlag |
| DtSettingsBackup * | mySettingsBackup |
| DtDe & | myDe |
Base class for shared settings managers.
Extends the functionality provided by the DtCommonBaseSettingsManager, by implementing the initializeBackup, setFromRecord, and getRecord methods. Since creating backups and setting/getting the settings' state with a record works the same for all shared settings managers, new shared settings managers should use DtBaseSharedSettingsManager as its base class to make use of the common code. The SettingsType template parameter must be a DtSharedSettings object with methods settingsBackup() (both const and non-const versions) and backup(), returning DtSettingsBackup* and void respectively. The settings object must also implement a void setFromRecord( const RecType& ) and a void getRecord( RecType& ) const method as well.
|
protected |
|
inline |
CTOR.
|
inlinevirtual |
Virtual DTOR.
|
inlinevirtual |
Creates a backup of the settings' current state.
Implements makVrv::DtCommonBaseSettingsManager< RecordType >.
|
inlinevirtual |
Set the current settings' state from the given record.
Implements makVrv::DtCommonBaseSettingsManager< RecordType >.
Reimplemented in makVrv::DtDisplayUnitsSettingsManager.
|
inlinevirtual |
Store the current settings' state in the given record.
Implements makVrv::DtCommonBaseSettingsManager< RecordType >.