diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-11-17 00:19:10 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-11-17 00:19:10 +0300 |
commit | 4825afb0187527d7eaa0ea3d903ad716a3eb9562 (patch) | |
tree | e516623a908eb6a8a4d053bbc39a36ff81aa4141 /src/input/inputitem.h | |
parent | b3d17866a3c5700b52c2b0b954fce132a52c1dbf (diff) | |
download | manaverse-4825afb0187527d7eaa0ea3d903ad716a3eb9562.tar.gz manaverse-4825afb0187527d7eaa0ea3d903ad716a3eb9562.tar.bz2 manaverse-4825afb0187527d7eaa0ea3d903ad716a3eb9562.tar.xz manaverse-4825afb0187527d7eaa0ea3d903ad716a3eb9562.zip |
Convert enum InputType into strong typed.
Diffstat (limited to 'src/input/inputitem.h')
-rw-r--r-- | src/input/inputitem.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/input/inputitem.h b/src/input/inputitem.h index 5abe34ad1..c3260ff03 100644 --- a/src/input/inputitem.h +++ b/src/input/inputitem.h @@ -21,20 +21,24 @@ #ifndef INPUT_INPUTITEM_H #define INPUT_INPUTITEM_H +#include "enums/input/inputtype.h" + #include "localconsts.h" struct InputItem final { InputItem() : - type(-1), + type(InputType::UNKNOWN), value(-1) { } - InputItem(const int type0, const int value0) : - type(type0), value(value0) + InputItem(const InputTypeT type0, + const int value0) : + type(type0), + value(value0) { } - int type; + InputTypeT type; int value; }; |