Simple loop.

This commit is contained in:
Jason Felds
2013-05-01 23:34:38 -04:00
parent ac9a8373d2
commit d64dd6721d
+7 -7
View File
@@ -40,20 +40,20 @@ class InputList: public BitmapText
vector<DeviceInput> DeviceInputs;
INPUTFILTER->GetPressedButtons( DeviceInputs );
FOREACH( DeviceInput, DeviceInputs, di )
for (DeviceInput const &di : DeviceInputs)
{
if( !di->bDown && di->level == 0.0f )
if( !di.bDown && di.level == 0.0f )
continue;
RString sTemp;
sTemp += INPUTMAN->GetDeviceSpecificInputString(*di);
if( di->level == 1.0f )
sTemp += INPUTMAN->GetDeviceSpecificInputString(di);
if( di.level == 1.0f )
sTemp += ssprintf(" - 1 " );
else
sTemp += ssprintf(" - %.3f ", di->level );
sTemp += ssprintf(" - %.3f ", di.level );
GameInput gi;
if( INPUTMAPPER->DeviceToGame(*di,gi) )
if( INPUTMAPPER->DeviceToGame(di,gi) )
{
RString sName = GameButtonToLocalizedString( INPUTMAPPER->GetInputScheme(), gi.button );
sTemp += ssprintf(" - %s %d %s", CONTROLLER.GetValue().c_str(), gi.controller+1, sName.c_str() );
@@ -73,7 +73,7 @@ class InputList: public BitmapText
sTemp += " - "+NOT_MAPPED.GetValue();
}
RString sComment = INPUTFILTER->GetButtonComment( *di );
RString sComment = INPUTFILTER->GetButtonComment( di );
if( sComment != "" )
sTemp += " - " + sComment;