summaryrefslogtreecommitdiff
path: root/src/gui/widgets/textfield.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/textfield.cpp')
-rw-r--r--src/gui/widgets/textfield.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/widgets/textfield.cpp b/src/gui/widgets/textfield.cpp
index d5fb58cb9..79c48beac 100644
--- a/src/gui/widgets/textfield.cpp
+++ b/src/gui/widgets/textfield.cpp
@@ -241,7 +241,7 @@ void TextField::keyPressed(gcn::KeyEvent &keyEvent)
case 6: // Ctrl+f
{
- unsigned sz = static_cast<unsigned>(mText.size());
+ const unsigned sz = static_cast<unsigned>(mText.size());
while (mCaretPosition < sz)
{
++mCaretPosition;
@@ -356,7 +356,7 @@ void TextField::keyPressed(gcn::KeyEvent &keyEvent)
case Input::KEY_GUI_RIGHT:
{
consumed = true;
- unsigned sz = static_cast<unsigned>(mText.size());
+ const unsigned sz = static_cast<unsigned>(mText.size());
while (mCaretPosition < sz)
{
++mCaretPosition;