diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-08-01 21:35:49 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-08-01 22:40:36 +0300 |
commit | fc854786ed73fe768d6a3ca22c02f7013560a930 (patch) | |
tree | 3a12f555d194679957559760567ff8eb701b494b /src/gui/chatwindow.cpp | |
parent | 09d74d9273cca445b7019edacaff53452a1eee3c (diff) | |
download | mv-fc854786ed73fe768d6a3ca22c02f7013560a930.tar.gz mv-fc854786ed73fe768d6a3ca22c02f7013560a930.tar.bz2 mv-fc854786ed73fe768d6a3ca22c02f7013560a930.tar.xz mv-fc854786ed73fe768d6a3ca22c02f7013560a930.zip |
Fix code style.
Diffstat (limited to 'src/gui/chatwindow.cpp')
-rw-r--r-- | src/gui/chatwindow.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/chatwindow.cpp b/src/gui/chatwindow.cpp index 75ec6d09c..0229f9da5 100644 --- a/src/gui/chatwindow.cpp +++ b/src/gui/chatwindow.cpp @@ -845,11 +845,12 @@ void ChatWindow::keyPressed(gcn::KeyEvent &event) ChatTab *tab = getFocused(); if (tab && tab->hasRows()) { - if (mChatHistoryIndex + 1 < tab->getRows().size()) + const size_t tabSize = tab->getRows().size(); + if (mChatHistoryIndex + 1 < tabSize) { mChatHistoryIndex ++; } - else if (mChatHistoryIndex < tab->getRows().size()) + else if (mChatHistoryIndex < tabSize) { mChatHistoryIndex ++; mChatInput->setText(""); |