Commit a38574a6 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

GIT_SILENT: minor qstring optimization

parent e7f6026d
......@@ -382,7 +382,7 @@ QVariantList appstreamActions(const KService::Ptr &service)
for(const auto &component: components) {
const QString componentId = component.id();
QVariantMap appstreamAction = Kicker::createActionItem(i18nc("@action opens a software center with the application", "Uninstall or Manage Add-Ons..."), "manageApplication", QVariant(QStringLiteral("appstream://") + componentId));
QVariantMap appstreamAction = Kicker::createActionItem(i18nc("@action opens a software center with the application", "Uninstall or Manage Add-Ons..."), "manageApplication", QVariant(QLatin1String("appstream://") + componentId));
appstreamAction[QStringLiteral("icon")] = QStringLiteral("plasmadiscover");
ret << appstreamAction;
}
......@@ -406,7 +406,7 @@ QString resolvedServiceEntryPath(const KService::Ptr &service)
{
QString path = service->entryPath();
if (!QDir::isAbsolutePath(path)) {
path = QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("kservices5/") + path);
path = QStandardPaths::locate(QStandardPaths::GenericDataLocation, QLatin1String("kservices5/") + path);
}
return path;
}
......
......@@ -251,7 +251,7 @@ KService::Ptr AppEntry::defaultAppByName(const QString& name)
if (browser.isEmpty()) {
return KMimeTypeTrader::self()->preferredService(QLatin1String("text/html"));
} else if (browser.startsWith(QLatin1Char('!'))) {
browser = browser.mid(1);
browser.remove(0, 1);
}
return KService::serviceByStorageId(browser);
......
......@@ -105,7 +105,7 @@ public:
// If this is an application, use the applications:-format url
auto appEntry = dynamic_cast<AppEntry*>(entry.data());
if (appEntry && !appEntry->menuId().isEmpty()) {
m_id = QStringLiteral("applications:") + appEntry->menuId();
m_id = QLatin1String("applications:") + appEntry->menuId();
return;
}
......
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