diff options
author | Max Horn | 2006-07-30 12:21:54 +0000 |
---|---|---|
committer | Max Horn | 2006-07-30 12:21:54 +0000 |
commit | 53f73eac8569010ccddfeebeddcdb2619b2616aa (patch) | |
tree | 542e09fc5045ea616390d07f6543dfb32845df98 /common/config-manager.h | |
parent | bd49091afd55cf2663095a1882bab34496ef01f0 (diff) | |
download | scummvm-rg350-53f73eac8569010ccddfeebeddcdb2619b2616aa.tar.gz scummvm-rg350-53f73eac8569010ccddfeebeddcdb2619b2616aa.tar.bz2 scummvm-rg350-53f73eac8569010ccddfeebeddcdb2619b2616aa.zip |
Added explicit string equals/hash functors to a new header common/hash-str.h; removed Hash functor specialization for String and char pointers; changed all code using hashmaps with string keys to explicitly specify whether they honor or ignore case
svn-id: r23634
Diffstat (limited to 'common/config-manager.h')
-rw-r--r-- | common/config-manager.h | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/common/config-manager.h b/common/config-manager.h index f7c1ce121b..364ca638ba 100644 --- a/common/config-manager.h +++ b/common/config-manager.h @@ -29,23 +29,10 @@ #include "common/hashmap.h" #include "common/singleton.h" #include "common/str.h" +#include "common/hash-str.h" namespace Common { -struct IgnoreCase_Less { - bool operator()(const String& x, const String& y) const { return scumm_stricmp(x.c_str(), y.c_str()) < 0; } -}; - -struct IgnoreCase_EqualTo { - bool operator()(const String& x, const String& y) const { return scumm_stricmp(x.c_str(), y.c_str()) == 0; } -}; - -struct IgnoreCase_Hash { - uint operator()(const String& x) const { return hashit_lower(x.c_str()); } -}; - -typedef HashMap<String, String, IgnoreCase_Hash, IgnoreCase_EqualTo> StringMap; - /** * The (singleton) configuration manager, used to query & set configuration * values using string keys. |