merge OverlayInput into Input. overlay screens can still intercept input if they want.

This commit is contained in:
Devin J. Pohly
2013-01-12 23:19:44 -05:00
parent 9c9e2f995f
commit 2cf9262afc
9 changed files with 17 additions and 31 deletions
+3 -5
View File
@@ -504,14 +504,12 @@ void ScreenManager::Input( const InputEventPlus &input )
// LOG->Trace( "ScreenManager::Input( %d-%d, %d-%d, %d-%d, %d-%d )",
// DeviceI.device, DeviceI.button, GameI.controller, GameI.button, MenuI.player, MenuI.button, StyleI.player, StyleI.col );
// First, give overlay screens a shot at the input. If OverlayInput returns
// true, it handled the input, so don't pass it further. OverlayInput could
// probably be merged with Input, but that would require changing all Input
// overloads, as well as all MenuLeft, etc. overloads.
// First, give overlay screens a shot at the input. If Input returns
// true, it handled the input, so don't pass it further.
for( unsigned i = 0; i < g_OverlayScreens.size(); ++i )
{
Screen *pScreen = g_OverlayScreens[i];
if( pScreen->OverlayInput(input) )
if( pScreen->Input(input) )
return;
}