summaryrefslogtreecommitdiff
path: root/plugingui/pluginconfig.cc
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2015-09-28 17:31:34 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2015-09-28 17:31:34 +0200
commit9d3d6b7c4ee891e28280af1651d8edb9357df643 (patch)
tree1d0e7745c3959e32982fdc947a8576344310c6cf /plugingui/pluginconfig.cc
parent5a0963274b2f21590fc72610ff49bba33145d161 (diff)
Refactored GUI::Config.
Diffstat (limited to 'plugingui/pluginconfig.cc')
-rw-r--r--plugingui/pluginconfig.cc33
1 files changed, 19 insertions, 14 deletions
diff --git a/plugingui/pluginconfig.cc b/plugingui/pluginconfig.cc
index d4c4477..77cb4ba 100644
--- a/plugingui/pluginconfig.cc
+++ b/plugingui/pluginconfig.cc
@@ -1,6 +1,6 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/***************************************************************************
- * config.cc
+ * pluginconfig.cc
*
* Tue Jun 3 13:54:05 CEST 2014
* Copyright 2014 Jonas Suhr Christensen
@@ -27,11 +27,13 @@
#include "pluginconfig.h"
#include <hugin.hpp>
-
+
#define CONFIGFILENAME "plugingui.conf"
+namespace GUI {
+
Config::Config()
- : ConfigFile(CONFIGFILENAME)
+ : ConfigFile(CONFIGFILENAME)
{
}
@@ -41,23 +43,26 @@ Config::~Config()
bool Config::load()
{
- lastkit.clear();
- lastmidimap.clear();
+ lastkit.clear();
+ lastmidimap.clear();
- if(!ConfigFile::load()) {
- return false;
- }
+ if(!ConfigFile::load())
+ {
+ return false;
+ }
- lastkit = getValue("lastkit");
- lastmidimap = getValue("lastmidimap");
+ lastkit = getValue("lastkit");
+ lastmidimap = getValue("lastmidimap");
- return true;
+ return true;
}
bool Config::save()
{
- setValue("lastkit", lastkit);
- setValue("lastmidimap", lastmidimap);
+ setValue("lastkit", lastkit);
+ setValue("lastmidimap", lastmidimap);
- return ConfigFile::save();
+ return ConfigFile::save();
}
+
+} // GUI::