forked from reddit/rpan-studio
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathobs-interaction.h
56 lines (47 loc) · 1.55 KB
/
obs-interaction.h
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
56
/******************************************************************************
Copyright (C) 2014 by Hugh Bailey <obs.jim@gmail.com>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
******************************************************************************/
#pragma once
#include "util/c99defs.h"
enum obs_interaction_flags {
INTERACT_NONE = 0,
INTERACT_CAPS_KEY = 1,
INTERACT_SHIFT_KEY = 1 << 1,
INTERACT_CONTROL_KEY = 1 << 2,
INTERACT_ALT_KEY = 1 << 3,
INTERACT_MOUSE_LEFT = 1 << 4,
INTERACT_MOUSE_MIDDLE = 1 << 5,
INTERACT_MOUSE_RIGHT = 1 << 6,
INTERACT_COMMAND_KEY = 1 << 7,
INTERACT_NUMLOCK_KEY = 1 << 8,
INTERACT_IS_KEY_PAD = 1 << 9,
INTERACT_IS_LEFT = 1 << 10,
INTERACT_IS_RIGHT = 1 << 11,
};
enum obs_mouse_button_type {
MOUSE_LEFT,
MOUSE_MIDDLE,
MOUSE_RIGHT,
};
struct obs_mouse_event {
uint32_t modifiers;
int32_t x;
int32_t y;
};
struct obs_key_event {
uint32_t modifiers;
char *text;
uint32_t native_modifiers;
uint32_t native_scancode;
uint32_t native_vkey;
};