diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-02-26 01:40:00 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-02-26 01:40:00 +0300 |
commit | d4febba47388979b26cd4680cb8a6f20e548e399 (patch) | |
tree | 2d520db672ed39b755e668828d27f0dd9d18ed6e /src/gui/widgets/browserbox.cpp | |
parent | 803b6afd00b0e3574b40b866f21a0d3d01f6dc4d (diff) | |
download | manaverse-d4febba47388979b26cd4680cb8a6f20e548e399.tar.gz manaverse-d4febba47388979b26cd4680cb8a6f20e548e399.tar.bz2 manaverse-d4febba47388979b26cd4680cb8a6f20e548e399.tar.xz manaverse-d4febba47388979b26cd4680cb8a6f20e548e399.zip |
Improve string usage in other files.
Diffstat (limited to 'src/gui/widgets/browserbox.cpp')
-rw-r--r-- | src/gui/widgets/browserbox.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gui/widgets/browserbox.cpp b/src/gui/widgets/browserbox.cpp index 51b977bbc..bbd31cee7 100644 --- a/src/gui/widgets/browserbox.cpp +++ b/src/gui/widgets/browserbox.cpp @@ -162,7 +162,7 @@ void BrowserBox::addRow(const std::string &row, const bool atTop) bLink.y1 = sz * font->getHeight(); bLink.y2 = bLink.y1 + font->getHeight(); - newRow += tmp.substr(0, idx1); + newRow.append(tmp.substr(0, idx1)); std::string tmp2 = newRow; idx1 = tmp2.find("##"); @@ -180,16 +180,16 @@ void BrowserBox::addRow(const std::string &row, const bool atTop) mLinks.push_back(bLink); linksCount ++; - newRow += "##<" + bLink.caption; + newRow.append("##<").append(bLink.caption); tmp.erase(0, idx3 + 2); if (!tmp.empty()) - newRow += "##>"; + newRow.append("##>"); idx1 = tmp.find("@@"); } - newRow += tmp; + newRow.append(tmp); } // Don't use links and user defined colors else @@ -768,7 +768,7 @@ std::string BrowserBox::getTextAtPos(const int x, const int y) const } else { - str += part.mText; + str.append(part.mText); } } |