[gnome-software] Do not show xdg-app remotes with noenumerate set



commit 1ec4a13cbaea76ec0213f0dd968e3f549f93e40a
Author: Richard Hughes <richard hughsie com>
Date:   Tue Feb 23 10:26:28 2016 +0000

    Do not show xdg-app remotes with noenumerate set
    
    These are remotes added from bundles and can only be used to update that
    specific application.

 src/plugins/gs-plugin-xdg-app.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/plugins/gs-plugin-xdg-app.c b/src/plugins/gs-plugin-xdg-app.c
index 4def3a2..1ed19ec 100644
--- a/src/plugins/gs-plugin-xdg-app.c
+++ b/src/plugins/gs-plugin-xdg-app.c
@@ -524,6 +524,12 @@ gs_plugin_add_sources (GsPlugin *plugin,
        for (i = 0; i < xremotes->len; i++) {
                XdgAppRemote *xremote = g_ptr_array_index (xremotes, i);
                g_autoptr(GsApp) app = NULL;
+
+               /* apps installed from bundles add their own remote that only
+                * can be used for updating that app only -- so hide them */
+               if (xdg_app_remote_get_noenumerate (xremote))
+                       continue;
+
                app = gs_app_new (xdg_app_remote_get_name (xremote));
                gs_app_set_management_plugin (app, "XgdApp");
                gs_app_set_kind (app, GS_APP_KIND_SOURCE);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]