mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 22:48:18 +00:00
skip screenshot when window isn't active. Closes #931
This commit is contained in:
parent
8c033a0e2e
commit
525e7ad7d4
|
@ -929,7 +929,8 @@ void CGraphics_SDL::Swap()
|
|||
{
|
||||
if(m_DoScreenshot)
|
||||
{
|
||||
ScreenshotDirect(m_aScreenshotName);
|
||||
if(WindowActive())
|
||||
ScreenshotDirect(m_aScreenshotName);
|
||||
m_DoScreenshot = false;
|
||||
}
|
||||
|
||||
|
|
|
@ -843,7 +843,8 @@ void CGraphics_Threaded::Swap()
|
|||
// TODO: screenshot support
|
||||
if(m_DoScreenshot)
|
||||
{
|
||||
ScreenshotDirect(m_aScreenshotName);
|
||||
if(WindowActive())
|
||||
ScreenshotDirect(m_aScreenshotName);
|
||||
m_DoScreenshot = false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue