From b6da7d8eb9009a47c085b4627912ecbb8a0e7374 Mon Sep 17 00:00:00 2001 From: Mark Cannon Date: Sun, 11 May 2008 20:58:31 +0000 Subject: [PATCH] Added TIMEOUT to SAStart, updated arcade binary git-svn-id: https://openitg.svn.sourceforge.net/svnroot/openitg@299 83fadc84-e282-4d84-a09a-c4228d6ae7e5 --- src/ScreenArcadeStart.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/ScreenArcadeStart.cpp b/src/ScreenArcadeStart.cpp index 44a9211b..7072e4c2 100644 --- a/src/ScreenArcadeStart.cpp +++ b/src/ScreenArcadeStart.cpp @@ -26,6 +26,9 @@ #define NEXT_SCREEN THEME->GetMetric( m_sName, "NextScreen" ) +/* automatic warning dismissal */ +const float TIMEOUT = 10.0f; + REGISTER_SCREEN_CLASS( ScreenArcadeStart ); ScreenArcadeStart::ScreenArcadeStart( CString sClassName ) : ScreenWithMenuElements( sClassName ) @@ -70,7 +73,7 @@ void ScreenArcadeStart::Update( float fDeltaTime ) m_bUSBError = !Refresh(); // problem was fixed, or we timed out - if( !m_bUSBError || m_Timer.Ago() > 10.0f ) + if( !m_bUSBError || m_Timer.Ago() > TIMEOUT ) { this->PlayCommand( "Off" ); StartTransitioning( SM_GoToNextScreen ); @@ -116,8 +119,8 @@ void ScreenArcadeStart::DrawPrimitives() bool ScreenArcadeStart::Refresh() { - float fTimer = 10.0f - m_Timer.Ago(); - CLAMP( fTimer, 0.0f, 10.0f); + float fTimer = TIMEOUT - m_Timer.Ago(); + CLAMP( fTimer, 0.0f, TIMEOUT); if( !HubIsConnected() ) { -- 2.11.0