// ------------------- public GamepadProfile GetProfile(string deviceName) { for (int i = 0; i < this.profileList.Count; ++i) { GamepadProfile profile = this.profileList[i]; if (profile.IsCompatible(deviceName)) { return(profile); } } return(null); }
// ------------------- public void GetCompatibleProfiles(string deviceName, List <GamepadProfile> targetList) { for (int i = 0; i < this.profileList.Count; ++i) { GamepadProfile profile = this.profileList[i]; if (profile.IsCompatible(deviceName)) { if (!targetList.Contains(profile)) { targetList.Add(profile); } } } }