From 2c9df769adfb9824dbdf9c5355aa9f7e16438066 Mon Sep 17 00:00:00 2001 From: bruvzg <7645683+bruvzg@users.noreply.github.com> Date: Mon, 20 May 2024 11:20:00 +0300 Subject: Clean Input::frame_parsed_events before de-initialising scripting languages to ensure no script created events exist at the exit. --- core/input/input.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'core/input/input.cpp') diff --git a/core/input/input.cpp b/core/input/input.cpp index a8409cc06d..4642ab5f90 100644 --- a/core/input/input.cpp +++ b/core/input/input.cpp @@ -1029,6 +1029,14 @@ void Input::parse_input_event(const Ref &p_event) { } } +#ifdef DEBUG_ENABLED +void Input::flush_frame_parsed_events() { + _THREAD_SAFE_METHOD_ + + frame_parsed_events.clear(); +} +#endif + void Input::flush_buffered_events() { _THREAD_SAFE_METHOD_ -- cgit v1.2.3