Plasma Engine  2.0
Loading...
Searching...
No Matches
InputDevice_android.h
1#pragma once
2
3#include <Core/Input/DeviceTypes/MouseKeyboard.h>
4
6struct AInputEvent;
7
10{
11 PL_ADD_DYNAMIC_REFLECTION(plStandardInputDevice, plInputDeviceMouseKeyboard);
12
13public:
14 plStandardInputDevice(plUInt32 uiWindowNumber);
16
17 virtual void SetShowMouseCursor(bool bShow) override;
18 virtual bool GetShowMouseCursor() const override;
19 virtual void SetClipMouseCursor(plMouseCursorClipMode::Enum mode) override;
20 virtual plMouseCursorClipMode::Enum GetClipMouseCursor() const override;
21
22private:
23 virtual void InitializeDevice() override;
24 virtual void RegisterInputSlots() override;
25 virtual void ResetInputSlotValues() override;
26
27private:
28 void AndroidInputEventHandler(plAndroidInputEvent& event);
29 void AndroidAppCommandEventHandler(plInt32 iCmd);
30 bool AndroidHandleInput(AInputEvent* pEvent);
31
32private:
33 plInt32 m_iResolutionX = 0;
34 plInt32 m_iResolutionY = 0;
35};
virtual void ResetInputSlotValues()
Override this, if you need to reset certain input slot values to zero, after the plInputManager is fi...
Definition InputDevice.h:118
virtual void InitializeDevice()=0
Override this if you need to do device specific initialization before the first use.
virtual void RegisterInputSlots()=0
Override this to register all the input slots that this device exposes.
This is the base class for all input devices that handle mouse and keyboard input.
Definition MouseKeyboard.h:26
virtual void SetShowMouseCursor(bool bShow)=0
Shows or hides the mouse cursor inside the application window.
virtual plMouseCursorClipMode::Enum GetClipMouseCursor() const =0
Returns whether the mouse is confined to the application window or not.
virtual void SetClipMouseCursor(plMouseCursorClipMode::Enum mode)=0
Will trap the mouse inside the application window. Should usually be enabled, to prevent accidental t...
virtual bool GetShowMouseCursor() const =0
Returns whether the mouse cursor is shown.
Android standard input device.
Definition InputDevice_android.h:10
Event fired by plAndroidUtils::s_InputEvent. Event listeners should inspect m_pEvent and set m_bHandl...
Definition AndroidUtils.h:20
Enum
Definition MouseKeyboard.h:10