summaryrefslogtreecommitdiff
path: root/plugingui/lineedit.cc
diff options
context:
space:
mode:
Diffstat (limited to 'plugingui/lineedit.cc')
-rw-r--r--plugingui/lineedit.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugingui/lineedit.cc b/plugingui/lineedit.cc
index 5e1eb9b..17d62bb 100644
--- a/plugingui/lineedit.cc
+++ b/plugingui/lineedit.cc
@@ -91,7 +91,7 @@ void GUI::LineEdit::buttonEvent(ButtonEvent *e)
if(readOnly()) return;
- if(e->direction == 1) {
+ if(e->direction == ButtonEvent::Down) {
for(int i = 0; i < (int)_visibletext.length(); i++) {
if(e->x < (int)(font.textWidth(_visibletext.substr(0, i)) + BORDER)) {
pos = i + offsetpos;
@@ -108,7 +108,7 @@ void GUI::LineEdit::keyEvent(GUI::KeyEvent *e)
bool change = false;
- if(e->direction == -1) {
+ if(e->direction == KeyEvent::Up) {
if(e->keycode == GUI::KeyEvent::KEY_LEFT) {
if(pos) pos--;