From 1018c9c5eb4e62d4479b92268bf2968672d8e595 Mon Sep 17 00:00:00 2001 From: Oliver Bock <oliver.bock@aei.mpg.de> Date: Tue, 13 May 2008 09:56:03 +0200 Subject: [PATCH] Using command line parameter for optional fullscreen startup * Tighter BOINC graphics app compliance * Idependent of debug/release mode --- main.C | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/main.C b/main.C index 0e9e7c1..6663da8 100644 --- a/main.C +++ b/main.C @@ -80,10 +80,14 @@ int main(int argc, char **argv) graphics->initialize(window.windowWidth(), window.windowHeight(), fontResource); graphics->refreshBOINCInformation(); -#ifdef NDEBUG - // switch to fullscreen when in release mode (on windoze: after init!) - window.toggleFullscreen(); -#endif + // check optional command line parameter + if(argc == 2) { + string param(argv[1]); + if(param == "--fullscreen") { + // switch to fullscreen (on windoze: after init!) + window.toggleFullscreen(); + } + } // enter main event loop window.eventLoop(); -- GitLab