From 2699cb7d324ffb1d2adc62e1f62434397aa39e2d Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Fri, 22 May 2015 08:35:53 +0200 Subject: Use new load return value from ConfigFile. --- plugingui/pluginconfig.cc | 12 ++++++++---- plugingui/pluginconfig.h | 4 ++-- 2 files changed, 10 insertions(+), 6 deletions(-) (limited to 'plugingui') diff --git a/plugingui/pluginconfig.cc b/plugingui/pluginconfig.cc index 0beef6e..d4c4477 100644 --- a/plugingui/pluginconfig.cc +++ b/plugingui/pluginconfig.cc @@ -39,21 +39,25 @@ Config::~Config() { } -void Config::load() +bool Config::load() { lastkit.clear(); lastmidimap.clear(); - ConfigFile::load(); + if(!ConfigFile::load()) { + return false; + } lastkit = getValue("lastkit"); lastmidimap = getValue("lastmidimap"); + + return true; } -void Config::save() +bool Config::save() { setValue("lastkit", lastkit); setValue("lastmidimap", lastmidimap); - ConfigFile::save(); + return ConfigFile::save(); } diff --git a/plugingui/pluginconfig.h b/plugingui/pluginconfig.h index 29d2ef5..9bef1f0 100644 --- a/plugingui/pluginconfig.h +++ b/plugingui/pluginconfig.h @@ -34,8 +34,8 @@ public: Config(); ~Config(); - void load(); - void save(); + bool load(); + bool save(); std::string lastkit; std::string lastmidimap; -- cgit v1.2.3