summaryrefslogtreecommitdiffstats
path: root/core/input/input.h
diff options
context:
space:
mode:
Diffstat (limited to 'core/input/input.h')
-rw-r--r--core/input/input.h19
1 files changed, 13 insertions, 6 deletions
diff --git a/core/input/input.h b/core/input/input.h
index c254650ef8..ec16871b72 100644
--- a/core/input/input.h
+++ b/core/input/input.h
@@ -96,14 +96,17 @@ private:
Vector3 gyroscope;
Vector2 mouse_pos;
int64_t mouse_window = 0;
+ bool legacy_just_pressed_behavior = false;
struct Action {
- uint64_t physics_frame;
- uint64_t process_frame;
- bool pressed;
- bool exact;
- float strength;
- float raw_strength;
+ uint64_t pressed_physics_frame = UINT64_MAX;
+ uint64_t pressed_process_frame = UINT64_MAX;
+ uint64_t released_physics_frame = UINT64_MAX;
+ uint64_t released_process_frame = UINT64_MAX;
+ bool pressed = false;
+ bool exact = true;
+ float strength = 0.0f;
+ float raw_strength = 0.0f;
};
HashMap<StringName, Action> action_state;
@@ -151,6 +154,9 @@ private:
VelocityTrack mouse_velocity_track;
HashMap<int, VelocityTrack> touch_velocity_track;
HashMap<int, Joypad> joy_names;
+
+ HashSet<uint32_t> ignored_device_ids;
+
int fallback_mapping = -1;
CursorShape default_shape = CURSOR_ARROW;
@@ -325,6 +331,7 @@ public:
bool is_joy_known(int p_device);
String get_joy_guid(int p_device) const;
+ bool should_ignore_device(int p_vendor_id, int p_product_id) const;
void set_fallback_mapping(String p_guid);
void flush_buffered_events();