Fullscreen fix

This commit is contained in:
2015-10-30 23:39:11 -07:00
parent 9160423fe8
commit 5fe40276a0
2 changed files with 21 additions and 14 deletions

View File

@@ -278,12 +278,14 @@ struct TestApplicationCallback : IApplicationCallback
mainWindow = app->newWindow(_S("YAY!"));
mainWindow->setCallback(&windowCallback);
mainWindow->showWindow();
mainWindow->setFullscreen(true);
devFinder.startScanning();
IGraphicsCommandQueue* gfxQ = mainWindow->getCommandQueue();
std::thread loaderThread(LoaderProc, this);
size_t frameIdx = 0;
size_t lastCheck = 0;
while (running)
{
mainWindow->waitForRetrace();
@@ -300,6 +302,12 @@ struct TestApplicationCallback : IApplicationCallback
gfxQ->execute();
fprintf(stderr, "%zu\n", frameIdx++);
if ((frameIdx - lastCheck) > 100)
{
lastCheck = frameIdx;
mainWindow->setFullscreen(!mainWindow->isFullscreen());
}
}
m_cv.notify_one();