summaryrefslogtreecommitdiff
path: root/src/resources/iteminfo.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-09-08 00:07:56 +0300
committerAndrei Karas <akaras@inbox.ru>2011-09-08 00:07:56 +0300
commitb3f70d8d46199524edc590269a73c262899763c7 (patch)
treeaf8e20371f2cc825c0b2dbe0c0e5c392a926c46d /src/resources/iteminfo.cpp
parent3f84fc198131ff706e18c56f612e38ff147b0005 (diff)
downloadmanaplus-b3f70d8d46199524edc590269a73c262899763c7.tar.gz
manaplus-b3f70d8d46199524edc590269a73c262899763c7.tar.bz2
manaplus-b3f70d8d46199524edc590269a73c262899763c7.tar.xz
manaplus-b3f70d8d46199524edc590269a73c262899763c7.zip
Replace most iterator to const_iterator.
Some other minor changes.
Diffstat (limited to 'src/resources/iteminfo.cpp')
-rw-r--r--src/resources/iteminfo.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/resources/iteminfo.cpp b/src/resources/iteminfo.cpp
index fb4b8ed5e..75e6e1d8c 100644
--- a/src/resources/iteminfo.cpp
+++ b/src/resources/iteminfo.cpp
@@ -185,7 +185,8 @@ std::string ItemInfo::getDyeColorsString(int color) const
if (!mColors || mColorList.empty())
return "";
- std::map <int, ColorDB::ItemColor>::iterator it = mColors->find(color);
+ std::map <int, ColorDB::ItemColor>::const_iterator
+ it = mColors->find(color);
if (it == mColors->end())
return "";
@@ -208,7 +209,8 @@ const std::string ItemInfo::replaceColors(std::string str,
std::string name;
if (mColors && !mColorList.empty())
{
- std::map <int, ColorDB::ItemColor>::iterator it = mColors->find(color);
+ std::map <int, ColorDB::ItemColor>::const_iterator
+ it = mColors->find(color);
if (it == mColors->end())
name = "unknown";
else