Commit ba9babb1 authored by Marco Martin's avatar Marco Martin

properly restore desktop icons

parent 6ede8da8
...@@ -136,8 +136,6 @@ void ApplicationListModel::loadApplications() ...@@ -136,8 +136,6 @@ void ApplicationListModel::loadApplications()
} else if (entry->property("Exec").isValid()) { } else if (entry->property("Exec").isValid()) {
KService::Ptr service(static_cast<KService* >(entry.data())); KService::Ptr service(static_cast<KService* >(entry.data()));
qDebug() << " desktopEntryName: " << service->desktopEntryName();
if (service->isApplication() && if (service->isApplication() &&
!blacklist.contains(service->desktopEntryName()) && !blacklist.contains(service->desktopEntryName()) &&
service->showOnCurrentPlatform() && service->showOnCurrentPlatform() &&
......
...@@ -57,8 +57,13 @@ LauncherContainer { ...@@ -57,8 +57,13 @@ LauncherContainer {
return root.flow; return root.flow;
} }
} }
Component.onCompleted: {
if (model.ApplicationLocationRole == ApplicationListModel.Desktop) {
appletsLayout.restoreItem(delegate);
}
}
onParentFromLocationChanged: { onParentFromLocationChanged: {
if (!editMode && parent != parentFromLocation) { if (!launcherDragManager.active && parent != parentFromLocation) {
parent = parentFromLocation; parent = parentFromLocation;
if (model.ApplicationLocationRole == ApplicationListModel.Favorites) { if (model.ApplicationLocationRole == ApplicationListModel.Favorites) {
plasmoid.nativeInterface.stackBefore(delegate, parentFromLocation.children[index]); plasmoid.nativeInterface.stackBefore(delegate, parentFromLocation.children[index]);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment