From e28dae5d10a107fcfda7bd0685a08e005776f245 Mon Sep 17 00:00:00 2001 From: JunjieBai Date: Mon, 6 Nov 2023 16:50:56 +0800 Subject: [PATCH] =?UTF-8?q?fix(app-search-plugin):=E5=BA=94=E7=94=A8?= =?UTF-8?q?=E5=9B=BE=E6=A0=87=E4=BD=BF=E7=94=A8qt=E7=9A=84icon=E5=BC=95?= =?UTF-8?q?=E6=93=8E=E6=89=BE=E4=B8=8D=E5=88=B0=EF=BC=8C=E6=8D=A2=E6=88=90?= =?UTF-8?q?xdg=E7=9A=84icon=E5=8A=A0=E8=BD=BD=E5=BC=95=E6=93=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- libsearch/appsearch/app-search-plugin.cpp | 2 +- libsearch/icon-loader.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libsearch/appsearch/app-search-plugin.cpp b/libsearch/appsearch/app-search-plugin.cpp index 3adf827..88920ee 100644 --- a/libsearch/appsearch/app-search-plugin.cpp +++ b/libsearch/appsearch/app-search-plugin.cpp @@ -191,7 +191,7 @@ void AppSearchPlugin::run() SearchPluginIface::ResultInfo ri; ri.name = data.value(SearchProperty::SearchResultProperty::ApplicationLocalName).toString(); - ri.icon = IconLoader::loadIconQt(data.value(SearchProperty::SearchResultProperty::ApplicationIconName).toString(), QIcon(":/res/icons/unknown.svg")); + ri.icon = IconLoader::loadIconXdg(data.value(SearchProperty::SearchResultProperty::ApplicationIconName).toString(), QIcon(":/res/icons/unknown.svg")); SearchPluginIface::DescriptionInfo description; description.key = QString(tr("Application Description:")); description.value = data.value(SearchProperty::SearchResultProperty::ApplicationDescription).toString(); diff --git a/libsearch/icon-loader.cpp b/libsearch/icon-loader.cpp index 2e0e8a4..7240224 100644 --- a/libsearch/icon-loader.cpp +++ b/libsearch/icon-loader.cpp @@ -18,6 +18,6 @@ QIcon IconLoader::loadIconQt(const QString &name, const QIcon &fallback) QIcon IconLoader::loadIconXdg(const QString &name, const QIcon &fallback) { QMutexLocker locker(&xdgIconMutex); - return XdgIcon::fromTheme("name",fallback); + return XdgIcon::fromTheme(name,fallback); } } // UkuiSearch \ No newline at end of file