/***************************************************************************
- * Copyright (C) 2005-07 by The Quassel IRC Development Team *
+ * Copyright (C) 2005-08 by the Quassel Project *
* devel@quassel-irc.org *
* *
* 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 *
* the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
+ * (at your option) version 3. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
#include <QStringList>
-CoreSettings::CoreSettings() : Settings("Core") {
+CoreSettings::CoreSettings(const QString group) : Settings(group, Global::coreApplicationName) {
}
CoreSettings::~CoreSettings() {
}
-void CoreSettings::setDatabaseSettings(const QVariant &data) {
- setLocalValue("DatabaseSettings", data);
+void CoreSettings::setStorageSettings(const QVariant &data) {
+ setLocalValue("StorageSettings", data);
}
-QVariant CoreSettings::databaseSettings(const QVariant &def) {
- return localValue("DatabaseSettings", def);
+QVariant CoreSettings::storageSettings(const QVariant &def) {
+ return localValue("StorageSettings", def);
+}
+
+// FIXME remove
+QVariant CoreSettings::oldDbSettings() {
+ return localValue("DatabaseSettings");
}
void CoreSettings::setPort(const uint &port) {
return localValue("Port", def).toUInt();
}
-QStringList CoreSettings::sessionKeys() {
- Q_ASSERT(false);
- return QStringList();
-}
-
-void CoreSettings::setSessionValue(const QString &key, const QVariant &data) {
- Q_ASSERT(false);
+void CoreSettings::setCoreState(const QVariant &data) {
+ setLocalValue("CoreState", data);
}
-QVariant CoreSettings::sessionValue(const QString &key, const QVariant &def) {
- Q_ASSERT(false);
- return QVariant();
+QVariant CoreSettings::coreState(const QVariant &def) {
+ return localValue("CoreState", def);
}