From 8b49d5cccac07ac2a3f1e2a6cfaee9b6e3b80f3e Mon Sep 17 00:00:00 2001 From: "j4ck.fr0st" Date: Sun, 17 Oct 2010 12:42:04 +0000 Subject: [PATCH] Don't store Render window size when the window is minimized (Fixes Issue 2940) git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6286 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/DolphinWX/Src/Frame.cpp | 5 +++-- Source/Core/DolphinWX/Src/FrameTools.cpp | 6 +++--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/Source/Core/DolphinWX/Src/Frame.cpp b/Source/Core/DolphinWX/Src/Frame.cpp index 4e17e6ca74..d5f5646098 100644 --- a/Source/Core/DolphinWX/Src/Frame.cpp +++ b/Source/Core/DolphinWX/Src/Frame.cpp @@ -579,7 +579,7 @@ void CFrame::OnMove(wxMoveEvent& event) event.Skip(); if (!IsMaximized() && - !(SConfig::GetInstance().m_LocalCoreStartupParameter.bRenderToMain && RendererIsFullscreen())) + !(SConfig::GetInstance().m_LocalCoreStartupParameter.bRenderToMain && RendererIsFullscreen())) { SConfig::GetInstance().m_LocalCoreStartupParameter.iPosX = GetPosition().x; SConfig::GetInstance().m_LocalCoreStartupParameter.iPosY = GetPosition().y; @@ -589,8 +589,9 @@ void CFrame::OnMove(wxMoveEvent& event) void CFrame::OnResize(wxSizeEvent& event) { event.Skip(); + if (!IsMaximized() && - !(SConfig::GetInstance().m_LocalCoreStartupParameter.bRenderToMain && RendererIsFullscreen())) + !(SConfig::GetInstance().m_LocalCoreStartupParameter.bRenderToMain && RendererIsFullscreen())) { SConfig::GetInstance().m_LocalCoreStartupParameter.iWidth = GetSize().GetWidth(); SConfig::GetInstance().m_LocalCoreStartupParameter.iHeight = GetSize().GetHeight(); diff --git a/Source/Core/DolphinWX/Src/FrameTools.cpp b/Source/Core/DolphinWX/Src/FrameTools.cpp index a7639456fe..bed2842fa3 100644 --- a/Source/Core/DolphinWX/Src/FrameTools.cpp +++ b/Source/Core/DolphinWX/Src/FrameTools.cpp @@ -703,7 +703,7 @@ void CFrame::OnRenderParentClose(wxCloseEvent& event) void CFrame::OnRenderParentMove(wxMoveEvent& event) { if (Core::GetState() != Core::CORE_UNINITIALIZED && - !RendererIsFullscreen() && !m_RenderFrame->IsMaximized()) + !RendererIsFullscreen() && !m_RenderFrame->IsMaximized() && !m_RenderFrame->IsIconized()) { SConfig::GetInstance().m_LocalCoreStartupParameter.iRenderWindowXPos = m_RenderFrame->GetPosition().x; SConfig::GetInstance().m_LocalCoreStartupParameter.iRenderWindowYPos = m_RenderFrame->GetPosition().y; @@ -717,7 +717,7 @@ void CFrame::OnRenderParentResize(wxSizeEvent& event) { int width, height; if (!SConfig::GetInstance().m_LocalCoreStartupParameter.bRenderToMain && - !RendererIsFullscreen() && !m_RenderFrame->IsMaximized()) + !RendererIsFullscreen() && !m_RenderFrame->IsMaximized() && !m_RenderFrame->IsIconized()) { m_RenderFrame->GetSize(&width, &height); SConfig::GetInstance().m_LocalCoreStartupParameter.iRenderWindowWidth = width; @@ -736,7 +736,7 @@ void CFrame::OnRenderParentResize(wxSizeEvent& event) event.Skip(); } -void CFrame::ToggleDisplayMode (bool bFullscreen) +void CFrame::ToggleDisplayMode(bool bFullscreen) { #ifdef _WIN32 if (bFullscreen)