[gnome-software] Never show addons as search results
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] Never show addons as search results
- Date: Mon, 4 Apr 2016 20:32:00 +0000 (UTC)
commit c5fee689ce9a1692cbfa92fb118154c5afaf6026
Author: Richard Hughes <richard hughsie com>
Date: Mon Apr 4 19:03:35 2016 +0100
Never show addons as search results
We should just show the parent application in all cases.
src/gs-plugin-loader.c | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/src/gs-plugin-loader.c b/src/gs-plugin-loader.c
index c7ec345..ac71140 100644
--- a/src/gs-plugin-loader.c
+++ b/src/gs-plugin-loader.c
@@ -387,7 +387,6 @@ static gboolean
gs_plugin_loader_app_is_valid_installed (GsApp *app, gpointer user_data)
{
switch (gs_app_get_kind (app)) {
- case AS_APP_KIND_ADDON:
case AS_APP_KIND_CODEC:
case AS_APP_KIND_FONT:
g_debug ("app invalid as %s: %s",
@@ -409,6 +408,13 @@ gs_plugin_loader_app_is_valid (GsApp *app, gpointer user_data)
{
GsPluginLoaderAsyncState *state = (GsPluginLoaderAsyncState *) user_data;
+ /* never show addons */
+ if (gs_app_get_kind (app) == AS_APP_KIND_ADDON) {
+ g_debug ("app invalid as addon %s",
+ gs_plugin_loader_get_app_str (app));
+ return FALSE;
+ }
+
/* don't show unknown state */
if (gs_app_get_state (app) == AS_APP_STATE_UNKNOWN) {
g_debug ("app invalid as state unknown %s",
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]