summaryrefslogtreecommitdiff
path: root/src/input
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-05-18 16:35:36 +0300
committerAndrei Karas <akaras@inbox.ru>2014-05-18 16:35:36 +0300
commit0d5fa0bc658e46269128bf23a9e981dfd9169de6 (patch)
tree913c8cb105ebfe8c37fa65a1a74b92e160e49364 /src/input
parent03c74387d37cefcc18e59db203d17d78cda40e8e (diff)
downloadmv-0d5fa0bc658e46269128bf23a9e981dfd9169de6.tar.gz
mv-0d5fa0bc658e46269128bf23a9e981dfd9169de6.tar.bz2
mv-0d5fa0bc658e46269128bf23a9e981dfd9169de6.tar.xz
mv-0d5fa0bc658e46269128bf23a9e981dfd9169de6.zip
Use mouseeventtype in mouseinput.
Diffstat (limited to 'src/input')
-rw-r--r--src/input/mouseinput.h22
1 files changed, 5 insertions, 17 deletions
diff --git a/src/input/mouseinput.h b/src/input/mouseinput.h
index 3e24543a8..284116db2 100644
--- a/src/input/mouseinput.h
+++ b/src/input/mouseinput.h
@@ -67,6 +67,7 @@
#include "input/mouseinput.h"
#include "events/mousebutton.h"
+#include "events/mouseeventtype.h"
#include "localconsts.h"
@@ -74,7 +75,7 @@ class MouseInput final
{
public:
MouseInput() :
- mType(0),
+ mType(MouseEventType::MOVED),
mButton(MouseButton::EMPTY),
mTimeStamp(0),
mX(0),
@@ -86,25 +87,12 @@ class MouseInput final
~MouseInput()
{ }
- /**
- * Mouse input event types. This enum partially corresponds
- * to the enum with event types in MouseEvent for easy mapping.
- */
- enum
- {
- MOVED = 0,
- PRESSED,
- RELEASED,
- WHEEL_MOVED_DOWN,
- WHEEL_MOVED_UP
- };
-
- void setType(unsigned int type)
+ void setType(MouseEventType::Type type)
{
mType = type;
}
- unsigned int getType() const
+ MouseEventType::Type getType() const
{
return mType;
}
@@ -176,7 +164,7 @@ class MouseInput final
/**
* Holds the type of the mouse input.
*/
- unsigned int mType;
+ MouseEventType::Type mType;
/**
* Holds the button of the mouse input.