ImGuiManager: Fix debug window interaction with frame limit off

This commit is contained in:
Connor McLaughlin 2023-01-11 18:42:39 +10:00
parent 8d3250667f
commit d096a09ed8
4 changed files with 20 additions and 6 deletions

View file

@ -786,11 +786,14 @@ void Host::RenderDisplay(bool skip_present)
if (!skip_present)
{
FullscreenUI::Render();
ImGuiManager::RenderOverlays();
ImGuiManager::RenderTextOverlays();
ImGuiManager::RenderOSD();
ImGuiManager::RenderDebugWindows();
}
// Debug windows are always rendered, otherwise mouse input breaks on skip.
ImGuiManager::RenderOverlayWindows();
ImGuiManager::RenderDebugWindows();
g_host_display->Render(skip_present);
ImGuiManager::NewFrame();

View file

@ -1450,11 +1450,14 @@ void EmuThread::renderDisplay(bool skip_present)
if (!skip_present)
{
FullscreenUI::Render();
ImGuiManager::RenderOverlays();
ImGuiManager::RenderTextOverlays();
ImGuiManager::RenderOSD();
ImGuiManager::RenderDebugWindows();
}
// Debug windows are always rendered, otherwise mouse input breaks on skip.
ImGuiManager::RenderOverlayWindows();
ImGuiManager::RenderDebugWindows();
g_host_display->Render(skip_present);
ImGuiManager::NewFrame();

View file

@ -128,7 +128,7 @@ static std::tuple<float, float> GetMinMax(gsl::span<const float> values)
static bool s_save_state_selector_ui_open = false;
void ImGuiManager::RenderOverlays()
void ImGuiManager::RenderTextOverlays()
{
const System::State state = System::GetState();
if (state != System::State::Shutdown)
@ -140,7 +140,14 @@ void ImGuiManager::RenderOverlays()
if (g_settings.display_show_inputs && state != System::State::Paused)
DrawInputsOverlay();
}
}
void ImGuiManager::RenderOverlayWindows()
{
const System::State state = System::GetState();
if (state != System::State::Shutdown)
{
if (s_save_state_selector_ui_open)
SaveStateSelectorUI::Draw();
}

View file

@ -6,7 +6,8 @@
#include "imgui_manager.h"
namespace ImGuiManager {
void RenderOverlays();
void RenderTextOverlays();
void RenderOverlayWindows();
}
namespace SaveStateSelectorUI {