blob: fc7b9f691221ba8296368cba1810d02e5489ae98 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
#ifndef _ASURA_ENGINE_INPUT_EVENT_H_
#define _ASURA_ENGINE_INPUT_EVENT_H_
#include <asura-base/Configure.h>
#include <asura-base/Classes.h>
#include <asura-base/Math/Vector2.hpp>
#include <windows.h>
#include <vector>
namespace_begin(AsuraEngine)
namespace_begin(Input)
// еĿͻ¼̡ػ桢
struct InputEvent
{
InputEvent();
~InputEvent();
#if ASURA_EDITOR
bool Open(HWND window);
void Close(void);
bool GetJoystickNames(std::vector<std::string> &names);
bool Activate(bool active);
bool ToggleFullscreen(bool fullscreen, HWND window);
bool Process(bool discard);
LRESULT OnKey(HWND window, UINT message, WPARAM wParam, LPARAM lParam);
LRESULT OnInput(HWND window, UINT message, WPARAM wParam, LPARAM lParam);
LRESULT OnDeviceChange(LPCWSTR name, bool add);
static bool ConvertPositionToClientAreaCoord(HWND activeWindow, POINT position, Vector2f& newPos);
#elif ASURA_RUNNER
bool Open();
#endif
enum
{
};
};
//InputEvent ConvertInputEvent();
namespace_end
namespace_end
#endif
|