Avoid double-lookup in UdevManager::devicesFromQuery
The current code fetchinstantiates all devices list of Udev objects, filters isOfInterest (which is atcreates a
least one device property lookup) then filters by type.
If we're searching for a specific type, we can do it much faster if westringlist of IDs discarding the backend devices. Then we loop through
creating a solid wrapper which then creates the Udev device by ID,
fetch devices by type from udev directly, and then filter the irrelevantforcing udev to reload the data for that object again.
ones.
KIO lik
This code creates to search for media players. According to hotspot this is ahe solid wrapper directly from the original
UdevDevice list.
really sore point in applications.
The filter logic is copied from UdevDevice, but applied in the initial
The isOfInterest check then needs to be added in this loop.
As it's slower than checking the type so this is done after
fetch. ParentUDI was hardcoded in UdevDevice so is here toowe check the types match.