summaryrefslogtreecommitdiff
path: root/plugingui/checkbox.cc
diff options
context:
space:
mode:
Diffstat (limited to 'plugingui/checkbox.cc')
-rw-r--r--plugingui/checkbox.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugingui/checkbox.cc b/plugingui/checkbox.cc
index 54e0787..c085be9 100644
--- a/plugingui/checkbox.cc
+++ b/plugingui/checkbox.cc
@@ -44,7 +44,7 @@ CheckBox::CheckBox(Widget *parent)
void CheckBox::buttonEvent(ButtonEvent *e)
{
- if(e->direction == -1 || e->doubleclick)
+ if(e->direction == ButtonEvent::Up || e->doubleclick)
{
middle = false;
internalSetChecked(!state);
@@ -67,7 +67,7 @@ void CheckBox::keyEvent(KeyEvent *e)
{
if(e->keycode == KeyEvent::KEY_CHARACTER && e->text == " ")
{
- if(e->direction == -1)
+ if(e->direction == KeyEvent::Up)
{
middle = false;
internalSetChecked(!state);