void Utility::updateFullscreenState() { video.clear(); if(config.video.isFullscreen == false) { config.video.context = &config.video.windowed; mainWindow->window->showNormal(); mainWindow->window->menuBar()->setVisible(true); mainWindow->window->statusBar()->setVisible(true); } else { config.video.context = &config.video.fullscreen; mainWindow->window->showFullScreen(); mainWindow->window->menuBar()->setVisible(!config.system.autoHideMenus); mainWindow->window->statusBar()->setVisible(!config.system.autoHideMenus); } application.processEvents(); #if defined(PLATFORM_X) //Xlib requires time to propogate fullscreen state change message to window manager; //if window is resized before this occurs, canvas may not resize correctly usleep(50000); #endif //refresh options that are unique to each video context resizeMainWindow(); updateVideoMode(); updateHardwareFilter(); updateSoftwareFilter(); mainWindow->syncUi(); }
void Utility::updateFullscreenState() { video.clear(); if(config.video.isFullscreen == false) { config.video.context = &config.video.windowed; winMain->window->showNormal(); } else { config.video.context = &config.video.fullscreen; winMain->window->showFullScreen(); } //Xlib requires time to propogate fullscreen state change message to window manager; //if window is resized before this occurs, canvas may not resize correctly application.processEvents(); usleep(50000); //refresh options that are unique to each video context resizeMainWindow(); updateVideoMode(); updateHardwareFilter(); updateSoftwareFilter(); winMain->syncUi(); }