Skip to content

Commit

Permalink
Adjust to KPackage KF6 API changes
Browse files Browse the repository at this point in the history
  • Loading branch information
zzag committed Mar 15, 2023
1 parent 9b750ba commit d2bf310
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/declarative/dynamicwallpapermodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#include <KAboutData>
#include <KConfigGroup>
#include <KLocalizedString>
#include <KPackage/PackageJob>
#include <KPackage/PackageLoader>
#include <KSharedConfig>

Expand Down Expand Up @@ -291,10 +292,8 @@ void DynamicWallpaperModelPrivate::removePackageWallpaper(const QModelIndex &ind

const QString dataLocation = QStandardPaths::writableLocation(QStandardPaths::GenericDataLocation);
const QString wallpaperPackageRoot = dataLocation + QStringLiteral("/wallpapers/");
KPackage::Package package =
KPackage::PackageLoader::self()->loadPackage(QStringLiteral("Wallpaper/Dynamic"));

KJob *uninstallJob = package.uninstall(wallpaper->packageName, wallpaperPackageRoot);
KJob *uninstallJob = KPackage::PackageJob::uninstall(QStringLiteral("Wallpaper/Dynamic"), wallpaper->packageName, wallpaperPackageRoot);

connect(uninstallJob, &KJob::finished, this, [this, imageUrl](KJob *job) {
if (job->error() != KJob::NoError)
Expand Down

0 comments on commit d2bf310

Please sign in to comment.