mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-10-14 06:40:23 +02:00
analytics: Collect less data about controllers.
The name field can contain personal information, particularly in the case of bluetooth devices on OSX which get configured with the user's full name.
This commit is contained in:
1 parent
ce4e6804a5
commit
2ec3a24e4e
3 files changed
+18
-5
No files matched your search
@@ -117,3 +117,17 @@ bool InputConfig::ControllersNeedToBeCreated() const
|
||||
{
|
||||
return m_controllers.empty();
|
||||
}
|
||||
|
||||
bool InputConfig::IsControllerControlledByGamepadDevice(int index) const
|
||||
{
|
||||
if (static_cast<size_t>(index) >= m_controllers.size())
|
||||
return false;
|
||||
|
||||
const auto& controller = m_controllers.at(index).get()->default_device;
|
||||
|
||||
// Filter out anything which obviously not a gamepad
|
||||
return !((controller.source == "Keyboard") // OSX Keyboard/Mouse
|
||||
|| (controller.source == "XInput2") // Linux and BSD Keyboard/Mouse
|
||||
|| (controller.source == "Android" && controller.name == "Touchscreen") // Android Touchscreen
|
||||
|| (controller.source == "DInput" && controller.name == "Keyboard Mouse")); // Windows Keyboard/Mouse
|
||||
}
|
||||
Reference in new issue
Block a user