DeviceManager: Move creating device info to main thread

This commit is contained in:
Jonas Kvinge
2025-06-22 17:21:12 +02:00
parent f6b38fecb0
commit 8cea020fac
4 changed files with 68 additions and 57 deletions

View File

@@ -97,8 +97,9 @@ class DeviceInfo : public SimpleTreeItem<DeviceInfo> {
void InitFromDb(const DeviceDatabaseBackend::Device &dev);
DeviceDatabaseBackend::Device SaveToDb() const;
void InitIcon();
// Tries to load a good icon for the device. Sets icon_name_ and icon_.
void SetIcon(const QVariantList &icons, const QString &name_hint);
void LoadIcon(const QVariantList &icons, const QString &name_hint);
// Gets the best backend available (the one with the highest priority)
const Backend *BestBackend() const;