Delete deviceinfo using parent object
This commit is contained in:
parent
6de0399807
commit
ebab9b7e4a
@ -256,7 +256,7 @@ void DeviceManager::AddDeviceFromDB(DeviceInfo *info) {
|
|||||||
existing->icon_ = info->icon_;
|
existing->icon_ = info->icon_;
|
||||||
QModelIndex idx = ItemToIndex(existing);
|
QModelIndex idx = ItemToIndex(existing);
|
||||||
if (idx.isValid()) emit dataChanged(idx, idx);
|
if (idx.isValid()) emit dataChanged(idx, idx);
|
||||||
delete info;
|
root_->Delete(info->row);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
qLog(Info) << "Device added from database: " << info->friendly_name_;
|
qLog(Info) << "Device added from database: " << info->friendly_name_;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user