summaryrefslogtreecommitdiff
path: root/src/gui/widgets/listbox.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/listbox.cpp')
-rw-r--r--src/gui/widgets/listbox.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gui/widgets/listbox.cpp b/src/gui/widgets/listbox.cpp
index 1df21af20..c41e32854 100644
--- a/src/gui/widgets/listbox.cpp
+++ b/src/gui/widgets/listbox.cpp
@@ -225,13 +225,13 @@ void ListBox::draw(Graphics *graphics)
BLOCK_END("ListBox::draw")
}
-void ListBox::keyPressed(KeyEvent &keyEvent)
+void ListBox::keyPressed(KeyEvent &event)
{
- const int action = keyEvent.getActionId();
+ const int action = event.getActionId();
if (action == Input::KEY_GUI_SELECT)
{
distributeActionEvent();
- keyEvent.consume();
+ event.consume();
}
else if (action == Input::KEY_GUI_UP)
{
@@ -239,7 +239,7 @@ void ListBox::keyPressed(KeyEvent &keyEvent)
setSelected(mSelected - 1);
else if (mSelected == 0 && mWrappingEnabled && getListModel())
setSelected(getListModel()->getNumberOfElements() - 1);
- keyEvent.consume();
+ event.consume();
}
else if (action == Input::KEY_GUI_DOWN)
{
@@ -248,17 +248,17 @@ void ListBox::keyPressed(KeyEvent &keyEvent)
setSelected(mSelected + 1);
else if (mSelected == num && mWrappingEnabled)
setSelected(0);
- keyEvent.consume();
+ event.consume();
}
else if (action == Input::KEY_GUI_HOME)
{
setSelected(0);
- keyEvent.consume();
+ event.consume();
}
else if (action == Input::KEY_GUI_END && getListModel())
{
setSelected(getListModel()->getNumberOfElements() - 1);
- keyEvent.consume();
+ event.consume();
}
}