diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-04-11 21:08:02 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-04-11 21:08:02 +0300 |
commit | aef5053e87c93a8987f89e4fdaf6cf3dd23efe81 (patch) | |
tree | 1114d14958b13eba28a51e57722d6c4da0b9d2e7 /src/gui/windows | |
parent | a50ecdf6045ba0f0d5e91d10ddeb8d5520ba55cb (diff) | |
download | manaplus-aef5053e87c93a8987f89e4fdaf6cf3dd23efe81.tar.gz manaplus-aef5053e87c93a8987f89e4fdaf6cf3dd23efe81.tar.bz2 manaplus-aef5053e87c93a8987f89e4fdaf6cf3dd23efe81.tar.xz manaplus-aef5053e87c93a8987f89e4fdaf6cf3dd23efe81.zip |
fix code style.
Diffstat (limited to 'src/gui/windows')
-rw-r--r-- | src/gui/windows/changeemaildialog.cpp | 4 | ||||
-rw-r--r-- | src/gui/windows/changepassworddialog.cpp | 6 | ||||
-rw-r--r-- | src/gui/windows/charcreatedialog.cpp | 2 | ||||
-rw-r--r-- | src/gui/windows/chatwindow.cpp | 6 | ||||
-rw-r--r-- | src/gui/windows/outfitwindow.cpp | 2 | ||||
-rw-r--r-- | src/gui/windows/registerdialog.cpp | 2 | ||||
-rw-r--r-- | src/gui/windows/unregisterdialog.cpp | 2 | ||||
-rw-r--r-- | src/gui/windows/updaterwindow.cpp | 4 |
8 files changed, 14 insertions, 14 deletions
diff --git a/src/gui/windows/changeemaildialog.cpp b/src/gui/windows/changeemaildialog.cpp index ce9ec84e8..0f4086a0b 100644 --- a/src/gui/windows/changeemaildialog.cpp +++ b/src/gui/windows/changeemaildialog.cpp @@ -119,8 +119,8 @@ void ChangeEmailDialog::action(const ActionEvent &event) else if (eventId == "change_email") { const std::string username = mLoginData->username.c_str(); - const std::string newFirstEmail = mFirstEmailField->getText(); - const std::string newSecondEmail = mSecondEmailField->getText(); + const std::string &newFirstEmail = mFirstEmailField->getText(); + const std::string &newSecondEmail = mSecondEmailField->getText(); logger->log("ChangeEmailDialog::Email change, Username is %s", username.c_str()); diff --git a/src/gui/windows/changepassworddialog.cpp b/src/gui/windows/changepassworddialog.cpp index 051fa6434..eb7380f20 100644 --- a/src/gui/windows/changepassworddialog.cpp +++ b/src/gui/windows/changepassworddialog.cpp @@ -98,9 +98,9 @@ void ChangePasswordDialog::action(const ActionEvent &event) else if (eventId == "change_password") { const std::string username = mLoginData->username.c_str(); - const std::string oldPassword = mOldPassField->getText(); - const std::string newFirstPass = mFirstPassField->getText(); - const std::string newSecondPass = mSecondPassField->getText(); + const std::string &oldPassword = mOldPassField->getText(); + const std::string &newFirstPass = mFirstPassField->getText(); + const std::string &newSecondPass = mSecondPassField->getText(); logger->log("ChangePasswordDialog::Password change, Username is %s", username.c_str()); diff --git a/src/gui/windows/charcreatedialog.cpp b/src/gui/windows/charcreatedialog.cpp index f0a9781f2..0fe412e5c 100644 --- a/src/gui/windows/charcreatedialog.cpp +++ b/src/gui/windows/charcreatedialog.cpp @@ -321,7 +321,7 @@ CharCreateDialog::~CharCreateDialog() void CharCreateDialog::action(const ActionEvent &event) { - const std::string id = event.getId(); + const std::string &id = event.getId(); if (id == "create") { if (getName().length() >= 4) diff --git a/src/gui/windows/chatwindow.cpp b/src/gui/windows/chatwindow.cpp index c3a3569f7..be2daf6a9 100644 --- a/src/gui/windows/chatwindow.cpp +++ b/src/gui/windows/chatwindow.cpp @@ -1021,7 +1021,7 @@ void ChatWindow::processEvent(const Channels channel, void ChatWindow::addInputText(const std::string &text, const bool space) { const int caretPos = mChatInput->getCaretPosition(); - const std::string inputText = mChatInput->getText(); + const std::string &inputText = mChatInput->getText(); std::ostringstream ss; ss << inputText.substr(0, caretPos) << text; @@ -1275,7 +1275,7 @@ void ChatWindow::autoComplete() { const int caretPos = mChatInput->getCaretPosition(); int startName = 0; - const std::string inputText = mChatInput->getText(); + const std::string &inputText = mChatInput->getText(); std::string name = inputText.substr(0, caretPos); for (int f = caretPos - 1; f > -1; f --) @@ -1643,7 +1643,7 @@ void ChatWindow::updateOnline(std::set<std::string> &onlinePlayers) const } else { - const std::string nick = tab->getNick(); + const std::string &nick = tab->getNick(); if (actorManager) { const Being *const being = actorManager->findBeingByName( diff --git a/src/gui/windows/outfitwindow.cpp b/src/gui/windows/outfitwindow.cpp index b1355ba46..601101bef 100644 --- a/src/gui/windows/outfitwindow.cpp +++ b/src/gui/windows/outfitwindow.cpp @@ -227,7 +227,7 @@ void OutfitWindow::save() const void OutfitWindow::action(const ActionEvent &event) { - const std::string eventId = event.getId(); + const std::string &eventId = event.getId(); if (eventId == "next") { next(); diff --git a/src/gui/windows/registerdialog.cpp b/src/gui/windows/registerdialog.cpp index 55a328fa8..6d3cf9d9f 100644 --- a/src/gui/windows/registerdialog.cpp +++ b/src/gui/windows/registerdialog.cpp @@ -182,7 +182,7 @@ void RegisterDialog::action(const ActionEvent &event) } else if (eventId == "register" && canSubmit()) { - const std::string user = mUserField->getText(); + const std::string &user = mUserField->getText(); logger->log("RegisterDialog::register Username is %s", user.c_str()); std::string errorMsg; diff --git a/src/gui/windows/unregisterdialog.cpp b/src/gui/windows/unregisterdialog.cpp index bb309c6f1..3d8627add 100644 --- a/src/gui/windows/unregisterdialog.cpp +++ b/src/gui/windows/unregisterdialog.cpp @@ -111,7 +111,7 @@ void UnRegisterDialog::action(const ActionEvent &event) else if (eventId == "unregister") { const std::string username = mLoginData->username.c_str(); - const std::string password = mPasswordField->getText(); + const std::string &password = mPasswordField->getText(); logger->log("UnregisterDialog::unregistered, Username is %s", username.c_str()); diff --git a/src/gui/windows/updaterwindow.cpp b/src/gui/windows/updaterwindow.cpp index 80275325a..824d8e0f6 100644 --- a/src/gui/windows/updaterwindow.cpp +++ b/src/gui/windows/updaterwindow.cpp @@ -1072,7 +1072,7 @@ void UpdaterWindow::loadDirMods(const std::string &dir) const ModInfo *const mod = (*modIt).second; if (mod) { - const std::string localDir = mod->getLocalDir(); + const std::string &localDir = mod->getLocalDir(); if (!localDir.empty()) resman->addToSearchPath(dir + "/" + localDir, false); } @@ -1095,7 +1095,7 @@ void UpdaterWindow::unloadMods(const std::string &dir) const ModInfo *const mod = (*modIt).second; if (mod) { - const std::string localDir = mod->getLocalDir(); + const std::string &localDir = mod->getLocalDir(); if (!localDir.empty()) resman->removeFromSearchPath(dir + "/" + localDir); } |