diff options
Diffstat (limited to 'src/configuration.h')
-rw-r--r-- | src/configuration.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/configuration.h b/src/configuration.h index 3e201dcb..0b2dc446 100644 --- a/src/configuration.h +++ b/src/configuration.h @@ -1,9 +1,8 @@ /* - * Aethyra + * The Mana World * Copyright (C) 2004 The Mana World Development Team * - * This file is part of Aethyra based on original code - * from The Mana World. + * This file is part of The Mana World. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -73,7 +72,7 @@ class ConfigurationObject friend class Configuration; public: - virtual ~ConfigurationObject(void); + virtual ~ConfigurationObject(); /** * Sets an option using a string value. @@ -110,7 +109,7 @@ class ConfigurationObject /** * Re-sets all data in the configuration */ - virtual void clear(void); + virtual void clear(); /** * Serialises a container into a list of configuration options @@ -127,7 +126,7 @@ class ConfigurationObject template <class IT, class T, class CONT> void setList(const std::string &name, IT begin, IT end, ConfigurationListManager<T, CONT> *manager) { - ConfigurationObject *nextobj = new ConfigurationObject(); + ConfigurationObject *nextobj = new ConfigurationObject; deleteList(name); ConfigurationList *list = &(mContainerOptions[name]); @@ -135,7 +134,7 @@ class ConfigurationObject ConfigurationObject *wrobj = manager->writeConfigItem(*it, nextobj); if (wrobj) { // wrote something assert (wrobj == nextobj); - nextobj = new ConfigurationObject(); + nextobj = new ConfigurationObject; list->push_back(wrobj); } else nextobj->clear(); // you never know... @@ -160,7 +159,7 @@ class ConfigurationObject { ConfigurationList *list = &(mContainerOptions[name]); CONT container = empty; - + for (ConfigurationList::const_iterator it = list->begin(); it != list->end(); it++) container = manager->readConfigItem(*it, container); @@ -189,7 +188,7 @@ class ConfigurationObject class Configuration : public ConfigurationObject { public: - virtual ~Configuration(void) {} + virtual ~Configuration() {} /** * Reads config file and parse all options into memory. @@ -216,6 +215,7 @@ class Configuration : public ConfigurationObject virtual void setValue(const std::string &key, std::string value); virtual void setValue(const std::string &key, float value); + private: typedef std::list<ConfigListener*> Listeners; typedef Listeners::iterator ListenerIterator; |