summaryrefslogtreecommitdiff
path: root/src/events/keyevent.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-05-31 13:41:23 +0300
committerAndrei Karas <akaras@inbox.ru>2014-05-31 13:41:23 +0300
commitd593fa58e641aa90d7e1f0759299c59d2665cca6 (patch)
treebdbce97f8a9ad8fb1f80477ea603e0452daf4614 /src/events/keyevent.h
parent1072eecf0e9e9140796d24f82d077199b2a1d9e6 (diff)
downloadplus-d593fa58e641aa90d7e1f0759299c59d2665cca6.tar.gz
plus-d593fa58e641aa90d7e1f0759299c59d2665cca6.tar.bz2
plus-d593fa58e641aa90d7e1f0759299c59d2665cca6.tar.xz
plus-d593fa58e641aa90d7e1f0759299c59d2665cca6.zip
Move keyeventtype into separate file.
Diffstat (limited to 'src/events/keyevent.h')
-rw-r--r--src/events/keyevent.h17
1 files changed, 5 insertions, 12 deletions
diff --git a/src/events/keyevent.h b/src/events/keyevent.h
index 16bc707c1..03e85438e 100644
--- a/src/events/keyevent.h
+++ b/src/events/keyevent.h
@@ -64,7 +64,9 @@
#ifndef EVENTS_KEYEVENT_H
#define EVENTS_KEYEVENT_H
+#include "events/keyeventtype.h"
#include "events/inputguievent.h"
+
#include "input/key.h"
#include <string>
@@ -78,15 +80,6 @@ class KeyEvent: public InputGuiEvent
{
public:
/**
- * Key event types.
- */
- enum
- {
- PRESSED = 0,
- RELEASED
- };
-
- /**
* Constructor.
*
* @param source The source widget of the event.
@@ -95,7 +88,7 @@ class KeyEvent: public InputGuiEvent
* @param key The key of the event.
*/
KeyEvent(Widget *const source,
- const unsigned int type,
+ KeyEventType::Type type,
const int actionId,
const Key &key) :
InputGuiEvent(source),
@@ -118,7 +111,7 @@ class KeyEvent: public InputGuiEvent
*
* @return The type of the event.
*/
- unsigned int getType() const A_WARN_UNUSED
+ KeyEventType::Type getType() const A_WARN_UNUSED
{ return mType; }
/**
@@ -153,7 +146,7 @@ class KeyEvent: public InputGuiEvent
/**
* Holds the type of the key event.
*/
- unsigned int mType;
+ KeyEventType::Type mType;
int mActionId;
};