Change GetDevicesAndDescriptions to fill in one vector instead of 2

Ignore changes in non-joystick devices when automapping
This commit is contained in:
Chris Danford
2006-02-27 17:51:27 +00:00
parent 0ac58078b4
commit bf0cc13a47
37 changed files with 148 additions and 124 deletions
+8 -7
View File
@@ -77,18 +77,19 @@ static bool ChangeAppPri()
#if defined(_WINDOWS)
if( g_BoostAppPriority == BOOST_AUTO )
{
vector<InputDevice> vDevices;
vector<RString> vDescriptions;
vector<InputDeviceInfo> vDevices;
// This can get called before INPUTMAN is constructed.
if( INPUTMAN )
{
INPUTMAN->GetDevicesAndDescriptions(vDevices,vDescriptions);
RString sInputDevices = join( ",", vDescriptions );
if( sInputDevices.find("NTPAD") != string::npos )
INPUTMAN->GetDevicesAndDescriptions(vDevices);
FOREACH_CONST( InputDeviceInfo, vDevices, d )
{
LOG->Trace( "Using NTPAD. Don't boost priority." );
return false;
if( d->sDesc.find("NTPAD") != string::npos )
{
LOG->Trace( "Using NTPAD. Don't boost priority." );
return false;
}
}
}
}