From: Marius Nita Date: Mon, 26 Aug 2002 15:00:14 +0000 (+0000) Subject: Fixed goof in config interface. All the functions are now named getValue(), since... X-Git-Url: https://git.brokenzipper.com/gitweb?a=commitdiff_plain;h=a95a6bd8e81a6bcc9db8abbbb3c0c78f087733f4;p=chaz%2Fopenbox Fixed goof in config interface. All the functions are now named getValue(), since they have different signatures. --- diff --git a/util/epist/config.cc b/util/epist/config.cc index db9ecddd..3e99e135 100644 --- a/util/epist/config.cc +++ b/util/epist/config.cc @@ -46,7 +46,7 @@ Config::~Config() } -bool Config::getStringValue(Config::StringType type, string &ret) const +bool Config::getValue(Config::StringType type, string &ret) const { StringItemList::const_iterator it = string_items.begin(), end = string_items.end(); for (; it != end; ++it) { @@ -59,7 +59,7 @@ bool Config::getStringValue(Config::StringType type, string &ret) const } -bool Config::getNumberValue(Config::NumberType type, int &ret) const +bool Config::getValue(Config::NumberType type, int &ret) const { NumberItemList::const_iterator it = number_items.begin(), end = number_items.end(); for (; it != end; ++it) { @@ -72,7 +72,7 @@ bool Config::getNumberValue(Config::NumberType type, int &ret) const } -bool Config::getBoolValue(Config::BoolType type, bool &ret) const +bool Config::getValue(Config::BoolType type, bool &ret) const { BoolItemList::const_iterator it = bool_items.begin(), end = bool_items.end(); for (; it != end; ++it) { diff --git a/util/epist/config.hh b/util/epist/config.hh index 0cb2a1c0..2c295747 100644 --- a/util/epist/config.hh +++ b/util/epist/config.hh @@ -63,9 +63,9 @@ public: Config(); ~Config(); - bool getBoolValue(BoolType, bool &) const; - bool getStringValue(StringType, std::string &) const; - bool getNumberValue(NumberType, int &) const; + bool getValue(BoolType, bool &) const; + bool getValue(StringType, std::string &) const; + bool getValue(NumberType, int &) const; void addOption(const std::string &, const std::string &); }; diff --git a/util/epist/keytree.cc b/util/epist/keytree.cc index 45b2fb53..30efa1be 100644 --- a/util/epist/keytree.cc +++ b/util/epist/keytree.cc @@ -222,7 +222,7 @@ void keytree::initialize(void) { int tval = 0; - _epist->getConfig()->getNumberValue(Config::chainTimeout, tval); + _epist->getConfig()->getValue(Config::chainTimeout, tval); _timer = new BTimer(_epist, this); if (tval <= 0) diff --git a/util/epist/screen.cc b/util/epist/screen.cc index de5c29c2..edaeb8f8 100644 --- a/util/epist/screen.cc +++ b/util/epist/screen.cc @@ -64,7 +64,7 @@ screen::screen(epist *epist, int number) _info = _epist->getScreenInfo(_number); _root = _info->getRootWindow(); - _config->getBoolValue(Config::stackedCycling, _stacked_cycling); + _config->getValue(Config::stackedCycling, _stacked_cycling); // find a window manager supporting NETWM, waiting for it to load if we must int count = 20; // try for 20 seconds @@ -672,7 +672,7 @@ void screen::changeWorkspaceVert(const int num) const { int active_desktop = (signed)_active_desktop; int wnum = 0; - _config->getNumberValue(Config::workspaceColumns, width); + _config->getValue(Config::workspaceColumns, width); if (width > num_desktops || width <= 0) return; @@ -704,7 +704,7 @@ void screen::changeWorkspaceHorz(const int num) const { int active_desktop = (signed)_active_desktop; int wnum = 0; - _config->getNumberValue(Config::workspaceColumns, width); + _config->getValue(Config::workspaceColumns, width); if (width > num_desktops || width <= 0) return;