mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
cleanup Engine.cpp a bit
This commit is contained in:
parent
4bafad708e
commit
01bf474a2b
5 changed files with 47 additions and 34 deletions
|
|
@ -67,6 +67,16 @@ void WindowControl::saveScreenshot() {
|
|||
logger.info() << "saved screenshot as " << filename.string();
|
||||
}
|
||||
|
||||
void WindowControl::toggleFullscreen() {
|
||||
auto& settings = engine.getSettings();
|
||||
auto& windowMode = settings.display.windowMode;
|
||||
if (windowMode.get() != static_cast<int>(WindowMode::FULLSCREEN)) {
|
||||
windowMode.set(static_cast<int>(WindowMode::FULLSCREEN));
|
||||
} else {
|
||||
windowMode.set(static_cast<int>(WindowMode::WINDOWED));
|
||||
}
|
||||
}
|
||||
|
||||
void WindowControl::nextFrame() {
|
||||
const auto& settings = engine.getSettings();
|
||||
auto& window = engine.getWindow();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue