Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix game window stops responding when debugger pauses #94452

Merged
merged 1 commit into from
Jul 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion core/debugger/remote_debugger.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
#include "core/io/resource_loader.h"
#include "core/object/script_language.h"
#include "core/os/os.h"
#include "servers/display_server.h"

class RemoteDebugger::PerformanceProfiler : public EngineProfiler {
Object *performance = nullptr;
Expand Down Expand Up @@ -539,7 +540,7 @@ void RemoteDebugger::debug(bool p_can_continue, bool p_is_error_breakpoint) {
OS::get_singleton()->delay_usec(10000);
if (Thread::get_caller_id() == Thread::get_main_id()) {
// If this is a busy loop on the main thread, events still need to be processed.
OS::get_singleton()->process_and_drop_events();
DisplayServer::get_singleton()->force_process_and_drop_events();
}
}
}
Expand Down
2 changes: 0 additions & 2 deletions core/os/os.h
Original file line number Diff line number Diff line change
Expand Up @@ -328,8 +328,6 @@ class OS {
virtual void benchmark_end_measure(const String &p_context, const String &p_what);
virtual void benchmark_dump();

virtual void process_and_drop_events() {}

virtual Error setup_remote_filesystem(const String &p_server_host, int p_port, const String &p_password, String &r_project_path);

enum PreferredTextureFormat {
Expand Down
Loading