diff options
author | Adrian Frühwirth | 2018-04-15 16:45:25 +0200 |
---|---|---|
committer | Adrian Frühwirth | 2018-04-15 16:45:25 +0200 |
commit | cf96f3f709797b2c7006bb06f5eed7ea723b2423 (patch) | |
tree | aaa205d3fdebd9f99dbf03ee1b13f08d518dc84c | |
parent | 3747d852eecb9e510a0b5cf0d03674f657f1b9e0 (diff) | |
download | scummvm-rg350-cf96f3f709797b2c7006bb06f5eed7ea723b2423.tar.gz scummvm-rg350-cf96f3f709797b2c7006bb06f5eed7ea723b2423.tar.bz2 scummvm-rg350-cf96f3f709797b2c7006bb06f5eed7ea723b2423.zip |
JANITORIAL: Indent GFXTransaction code blocks
-rw-r--r-- | engines/sherlock/scalpel/scalpel.cpp | 4 | ||||
-rw-r--r-- | engines/testbed/graphics.cpp | 41 | ||||
-rw-r--r-- | engines/wintermute/base/gfx/osystem/base_render_osystem.cpp | 2 |
3 files changed, 24 insertions, 23 deletions
diff --git a/engines/sherlock/scalpel/scalpel.cpp b/engines/sherlock/scalpel/scalpel.cpp index 2aa6ae8902..fbe025c0b7 100644 --- a/engines/sherlock/scalpel/scalpel.cpp +++ b/engines/sherlock/scalpel/scalpel.cpp @@ -258,8 +258,8 @@ void ScalpelEngine::setupGraphics() { // First try for a 640x400 mode g_system->beginGFXTransaction(); - initCommonGFX(); - g_system->initSize(640, 400, &pixelFormatRGB565); + initCommonGFX(); + g_system->initSize(640, 400, &pixelFormatRGB565); OSystem::TransactionError gfxError = g_system->endGFXTransaction(); if (gfxError == OSystem::kTransactionSuccess) { diff --git a/engines/testbed/graphics.cpp b/engines/testbed/graphics.cpp index 1b5af76ee7..589c95de3b 100644 --- a/engines/testbed/graphics.cpp +++ b/engines/testbed/graphics.cpp @@ -464,7 +464,7 @@ TestExitStatus GFXtests::fullScreenMode() { } g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureFullscreenMode, !isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureFullscreenMode, !isFeatureEnabled); g_system->endGFXTransaction(); // Current state should be now !isFeatureEnabled @@ -482,7 +482,7 @@ TestExitStatus GFXtests::fullScreenMode() { } g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureFullscreenMode, !isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureFullscreenMode, !isFeatureEnabled); g_system->endGFXTransaction(); g_system->delayMillis(1000); @@ -536,7 +536,7 @@ TestExitStatus GFXtests::filteringMode() { if (g_system->hasFeature(OSystem::kFeatureFullscreenMode) && !g_system->getFeatureState(OSystem::kFeatureFullscreenMode)) { fullScreenToggled = true; g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureFullscreenMode, true); + g_system->setFeatureState(OSystem::kFeatureFullscreenMode, true); g_system->endGFXTransaction(); } @@ -557,7 +557,7 @@ TestExitStatus GFXtests::filteringMode() { } g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureFilteringMode, !isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureFilteringMode, !isFeatureEnabled); g_system->endGFXTransaction(); // Current state should be now !isFeatureEnabled @@ -575,7 +575,7 @@ TestExitStatus GFXtests::filteringMode() { } g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureFilteringMode, !isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureFilteringMode, !isFeatureEnabled); g_system->endGFXTransaction(); g_system->delayMillis(1000); @@ -591,7 +591,7 @@ TestExitStatus GFXtests::filteringMode() { // Restore fullscreen state if (fullScreenToggled) { g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureFullscreenMode, false); + g_system->setFeatureState(OSystem::kFeatureFullscreenMode, false); g_system->endGFXTransaction(); } @@ -639,7 +639,7 @@ TestExitStatus GFXtests::aspectRatio() { } g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, !isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, !isFeatureEnabled); g_system->endGFXTransaction(); g_system->delayMillis(1000); @@ -653,7 +653,7 @@ TestExitStatus GFXtests::aspectRatio() { } g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, isFeatureEnabled); g_system->endGFXTransaction(); } else { Testsuite::displayMessage("feature not supported"); @@ -835,13 +835,13 @@ TestExitStatus GFXtests::iconifyWindow() { // Toggle g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureIconifyWindow, !isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureIconifyWindow, !isFeatureEnabled); g_system->endGFXTransaction(); g_system->delayMillis(1000); g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureIconifyWindow, isFeatureEnabled); + g_system->setFeatureState(OSystem::kFeatureIconifyWindow, isFeatureEnabled); g_system->endGFXTransaction(); } else { Testsuite::displayMessage("feature not supported"); @@ -884,7 +884,7 @@ TestExitStatus GFXtests::scaledCursors() { if (isAspectRatioCorrected) { g_system->beginGFXTransaction(); - g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, false); + g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, false); g_system->endGFXTransaction(); } @@ -911,8 +911,8 @@ TestExitStatus GFXtests::scaledCursors() { g_system->beginGFXTransaction(); - bool isGFXModeSet = g_system->setGraphicsMode(gfxMode->id); - g_system->initSize(320, 200); + bool isGFXModeSet = g_system->setGraphicsMode(gfxMode->id); + g_system->initSize(320, 200); OSystem::TransactionError gfxError = g_system->endGFXTransaction(); @@ -947,12 +947,13 @@ TestExitStatus GFXtests::scaledCursors() { // Restore Original State g_system->beginGFXTransaction(); - bool isGFXModeSet = g_system->setGraphicsMode(currGFXMode); - g_system->initSize(320, 200); - if (isAspectRatioCorrected) { - g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, true); - } + bool isGFXModeSet = g_system->setGraphicsMode(currGFXMode); + g_system->initSize(320, 200); + + if (isAspectRatioCorrected) { + g_system->setFeatureState(OSystem::kFeatureAspectRatioCorrection, true); + } OSystem::TransactionError gfxError = g_system->endGFXTransaction(); @@ -1226,7 +1227,7 @@ TestExitStatus GFXtests::pixelFormats() { // Switch to that pixel Format g_system->beginGFXTransaction(); - g_system->initSize(320, 200, &(*iter)); + g_system->initSize(320, 200, &(*iter)); g_system->endGFXTransaction(); Testsuite::clearScreen(true); @@ -1272,7 +1273,7 @@ TestExitStatus GFXtests::pixelFormats() { // Revert back to 8bpp g_system->beginGFXTransaction(); - g_system->initSize(320, 200); + g_system->initSize(320, 200); g_system->endGFXTransaction(); GFXTestSuite::setCustomColor(255, 0, 0); initMousePalette(); diff --git a/engines/wintermute/base/gfx/osystem/base_render_osystem.cpp b/engines/wintermute/base/gfx/osystem/base_render_osystem.cpp index 0f6a184cb3..15cd33d28c 100644 --- a/engines/wintermute/base/gfx/osystem/base_render_osystem.cpp +++ b/engines/wintermute/base/gfx/osystem/base_render_osystem.cpp @@ -125,7 +125,7 @@ bool BaseRenderOSystem::initRenderer(int width, int height, bool windowed) { Graphics::PixelFormat format(4, 8, 8, 8, 8, 24, 16, 8, 0); g_system->beginGFXTransaction(); - g_system->initSize(_width, _height, &format); + g_system->initSize(_width, _height, &format); OSystem::TransactionError gfxError = g_system->endGFXTransaction(); if (gfxError != OSystem::kTransactionSuccess) { |