Commit f8d52d0c authored by Aleix Pol Gonzalez's avatar Aleix Pol Gonzalez 🐧 Committed by Aleix Pol Gonzalez
Browse files

pk: sort the updated package in offline updates description

Makes it easier to see if a specific package is being upgraded.

(cherry picked from commit fc496ad4)
parent f69c6353
......@@ -104,13 +104,14 @@ public:
return i18np("1 package to upgrade", "%1 packages to upgrade", m_resources.count());
void fetchChangelog() override {
QString changes;
QStringList changes;
for (auto res : qAsConst(m_resources)) {
const auto versions = res->upgradeText();
const auto idx = versions.indexOf(u'\u009C');
changes += QStringLiteral("<li>") + res->packageName() + QStringLiteral(": ") + versions.leftRef(idx) + QStringLiteral("</li>\n");
Q_EMIT changelogFetched(QStringLiteral("<ul>") + changes + QStringLiteral("</ul>\n"));
Q_EMIT changelogFetched(QStringLiteral("<ul>") + changes.join(QString()) + QStringLiteral("</ul>\n"));
QString installedVersion() const override { return i18n("Present"); }
Supports Markdown
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