mirror of https://github.com/PCSX2/pcsx2.git
GSdx: Fixed crash when minimizing GS window and alt-tabbing out of fullscreen.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@1462 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
43e41bf160
commit
2a5a32d359
|
@ -74,6 +74,10 @@ void GSDevice::Present(const GSVector4i& r, int shader)
|
||||||
{
|
{
|
||||||
GSVector4i cr = m_wnd->GetClientRect();
|
GSVector4i cr = m_wnd->GetClientRect();
|
||||||
|
|
||||||
|
// Skip Presentation if the surface is invisible (minimized or hidden); prevents DX null swapchain crashes.
|
||||||
|
if(cr.width() == 0 || cr.height() == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
if(m_backbuffer->GetWidth() != cr.width() || m_backbuffer->GetHeight() != cr.height())
|
if(m_backbuffer->GetWidth() != cr.width() || m_backbuffer->GetHeight() != cr.height())
|
||||||
{
|
{
|
||||||
Reset(cr.width(), cr.height(), false);
|
Reset(cr.width(), cr.height(), false);
|
||||||
|
|
Loading…
Reference in New Issue