From 18405a713c771423d31ffcb927fd224f77d92539 Mon Sep 17 00:00:00 2001 From: Connor McLaughlin Date: Mon, 1 Feb 2021 00:50:47 +1000 Subject: [PATCH] FullscreenUI: Fix debug windows not drawing --- src/frontend-common/common_host_interface.h | 8 +++++--- src/frontend-common/fullscreen_ui.cpp | 6 ++++++ 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/frontend-common/common_host_interface.h b/src/frontend-common/common_host_interface.h index 96953fe2e..b7f850dab 100644 --- a/src/frontend-common/common_host_interface.h +++ b/src/frontend-common/common_host_interface.h @@ -263,6 +263,11 @@ public: bool IsTurboEnabled() const { return m_turbo_enabled; } void SetTurboEnabled(bool enabled); + /// ImGui window drawing. + void DrawFPSWindow(); + void DrawOSDMessages(); + void DrawDebugWindows(); + protected: enum : u32 { @@ -369,9 +374,6 @@ protected: virtual void DrawImGuiWindows(); - void DrawFPSWindow(); - void DrawOSDMessages(); - void DrawDebugWindows(); void DoFrameStep(); void DoToggleCheats(); diff --git a/src/frontend-common/fullscreen_ui.cpp b/src/frontend-common/fullscreen_ui.cpp index 55896ffff..ae903d2dd 100644 --- a/src/frontend-common/fullscreen_ui.cpp +++ b/src/frontend-common/fullscreen_ui.cpp @@ -264,9 +264,15 @@ void Shutdown() void Render() { if (s_debug_menu_enabled) + { DrawDebugMenu(); + if (System::IsValid()) + s_host_interface->DrawDebugWindows(); + } else if (System::IsValid()) + { DrawStatsOverlay(); + } ImGuiFullscreen::BeginLayout();