/******************************************************************************* * * * Société de Transports de Montréal. * * 2012 * * * * Projet Zones Tests * * * * * * * *******************************************************************************/ /* Description: Le main. */ /* ************************************************************************** */ /* Revision: ### 20121210 JFM Verision d'origine. ### YYYYMMDD Description du besoin ou du bug Description du changement. */ /* ************************************************************************** */ #include #include "Zonetest.h" #include "MainPanel.h" #include int main(int argc, char *argv[]) { QApplication::setGraphicsSystem("raster"); //Qt Mainframe application instance. QApplication a(argc, argv); QFont serifFont("Times", 10, QFont::Bold); QApplication::setFont(serifFont); //Create program instance CZoneTest ZoneTest; bool FullScreen = true; bool SimulLazerProbes = false; bool IgnoreStationKey = false; bool DisablePassword = false; bool UseWatchdog = true; for ( int i = 1 ; i < argc ; i ++ ) { // qDebug("%d %s",i,argv[i]); if ( strcmp(argv[i],"-windowed") == 0 ) { FullScreen = false; } else if ( strcmp(argv[i],"-simullazer") == 0 ) { SimulLazerProbes = true; } else if ( strcmp(argv[i],"-ignorekey") == 0 ) { IgnoreStationKey = true; } else if ( strcmp(argv[i],"-disablepassword") == 0 ) { DisablePassword = true; } else if ( strcmp(argv[i],"-disablewatchdog") == 0 ) { UseWatchdog = false; } } ZoneTest.mFullScreen = FullScreen; ZoneTest.mSimulateLazerProbes = SimulLazerProbes; ZoneTest.mIgnoreStationPhysicalKey = IgnoreStationKey; ZoneTest.mDisablePassword = DisablePassword; ZoneTest.mUseWatchdog = UseWatchdog; //setup stdout for screen printing. setvbuf(stdout, NULL, _IONBF, 0 ); //Run Zone Tests ZoneTest.Start(); return a.exec(); }