Fix minor code issues

This commit is contained in:
Jonas Kvinge
2019-09-15 20:27:32 +02:00
parent 83e10aac27
commit 2d67279180
147 changed files with 644 additions and 329 deletions

View File

@@ -757,6 +757,8 @@ DeviceLister *DeviceManager::GetLister(QModelIndex idx) const {
void DeviceManager::Disconnect(DeviceInfo *info, QModelIndex idx) {
Q_UNUSED(idx);
info->device_->Close();
}
@@ -901,6 +903,8 @@ void DeviceManager::Unmount(QModelIndex idx) {
void DeviceManager::DeviceSongCountUpdated(int count) {
Q_UNUSED(count);
ConnectedDevice *device = qobject_cast<ConnectedDevice*>(sender());
if (!device) return;
@@ -915,11 +919,14 @@ void DeviceManager::DeviceSongCountUpdated(int count) {
}
void DeviceManager::LazyPopulate(DeviceInfo *parent, bool signal) {
Q_UNUSED(signal);
if (parent->lazy_loaded) return;
parent->lazy_loaded = true;
}
QString DeviceManager::DeviceNameByID(QString unique_id) {
QString DeviceManager::DeviceNameByID(const QString &unique_id) {
DeviceInfo *info = FindDeviceById(unique_id);
if (!info) return QString();