diff options
| author | Jules Blok <jules.blok@gmail.com> | 2015-06-10 00:00:12 +0200 |
|---|---|---|
| committer | Jules Blok <jules.blok@gmail.com> | 2015-06-10 00:00:12 +0200 |
| commit | 7dfced21a2e5aac7195e0e1ad76468e30306766b (patch) | |
| tree | bd671b639d3d911460b767caabad8fc8a759a6bf /Source/Core/InputCommon/ControllerInterface/Android/Android.h | |
| parent | c25be031fc1031d795157d8344b87b7841145197 (diff) | |
| parent | 7b0a65e295c784f9d573f2ef52d4e2a7b9bb2889 (diff) | |
Merge branch 'master' into stable
Diffstat (limited to 'Source/Core/InputCommon/ControllerInterface/Android/Android.h')
| -rw-r--r-- | Source/Core/InputCommon/ControllerInterface/Android/Android.h | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/Source/Core/InputCommon/ControllerInterface/Android/Android.h b/Source/Core/InputCommon/ControllerInterface/Android/Android.h new file mode 100644 index 0000000000..35b68cdd71 --- /dev/null +++ b/Source/Core/InputCommon/ControllerInterface/Android/Android.h @@ -0,0 +1,53 @@ +// Copyright 2008 Dolphin Emulator Project +// Licensed under GPLv2+ +// Refer to the license.txt file included. + +#pragma once + +#include "DolphinWX/Android/ButtonManager.h" +#include "InputCommon/ControllerInterface/Device.h" + +namespace ciface +{ +namespace Android +{ + +void Init( std::vector<Core::Device*>& devices ); +class Touchscreen : public Core::Device +{ +private: + class Button : public Input + { + public: + std::string GetName() const; + Button(int padID, ButtonManager::ButtonType index) : _padID(padID), _index(index) {} + ControlState GetState() const; + private: + const int _padID; + const ButtonManager::ButtonType _index; + }; + class Axis : public Input + { + public: + std::string GetName() const; + Axis(int padID, ButtonManager::ButtonType index, float neg = 1.0f) : _padID(padID), _index(index), _neg(neg) {} + ControlState GetState() const; + private: + const int _padID; + const ButtonManager::ButtonType _index; + const float _neg; + }; + +public: + Touchscreen(int padID); + ~Touchscreen() {} + + std::string GetName() const; + int GetId() const; + std::string GetSource() const; +private: + const int _padID; +}; + +} +} |
