diff --git a/package.cpp b/package.cpp index 8e1fca394..32878bdfa 100644 --- a/package.cpp +++ b/package.cpp @@ -197,7 +197,7 @@ QStringList Package::knownPackages(const QString& packageRoot) // static QString metadata = packageRoot + '/' + sdir + "/metadata.desktop"; if (QFile::exists(metadata)) { PackageMetadata m(metadata); - packages << m.name(); + packages << m.pluginName(); } } @@ -247,10 +247,10 @@ bool Package::installPackage(const QString& package, return false; } PackageMetadata meta(metadataPath); - QString targetName = meta.name(); + QString targetName = meta.pluginName(); if (targetName.isEmpty()) { - kWarning(505) << "Package name not specified"; + kWarning(505) << "Package plugin name not specified"; return false; } diff --git a/packagemetadata.cpp b/packagemetadata.cpp index c9d71d981..5c7fb0e82 100644 --- a/packagemetadata.cpp +++ b/packagemetadata.cpp @@ -77,7 +77,6 @@ void PackageMetadata::write(const QString &filename, const QString &icon) const KConfigGroup config = cfg.desktopGroup(); config.writeEntry("Encoding", "UTF-8"); - //TODO: this will be a problem for localized names? config.writeEntry("Name", d->name); config.writeEntry("Comment", d->description); if (!icon.isNull()) { @@ -101,10 +100,10 @@ void PackageMetadata::read(const QString& filename) KConfig cfg(filename); KConfigGroup config(&cfg, "Desktop Entry"); - //TODO: this will be a problem for localized names? - d->name = config.readEntry("X-KDE-PluginInfo-Name", d->name); - d->description = config.readEntry("Description", d->description); + d->name = config.readEntry("Name", d->name); + d->description = config.readEntry("Comment", d->description); d->serviceType = config.readEntry("X-KDE-ServiceTypes", d->serviceType); + d->pluginName = config.readEntry("X-KDE-PluginInfo-Name", d->pluginName); d->author = config.readEntry("X-KDE-PluginInfo-Author", d->author); d->email = config.readEntry("X-KDE-PluginInfo-Email", d->email); d->version = config.readEntry("X-KDE-PluginInfo-Version", d->version);