[gnome-software/1166-repository-dialog-design-updates: 49/51] plugins: Ensure management plugin being set on repositories




commit b7bd59b2d7945e173dede928a88125910f520311
Author: Milan Crha <mcrha redhat com>
Date:   Tue Jul 27 14:43:12 2021 +0200

    plugins: Ensure management plugin being set on repositories
    
    This will be used to split the repositories into correct sections
    in a later commit.

 plugins/dummy/gs-plugin-dummy.c                                       | 1 +
 plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c | 1 +
 plugins/flatpak/gs-flatpak-utils.c                                    | 1 +
 plugins/fwupd/gs-plugin-fwupd.c                                       | 1 +
 4 files changed, 4 insertions(+)
---
diff --git a/plugins/dummy/gs-plugin-dummy.c b/plugins/dummy/gs-plugin-dummy.c
index 4c49f446c..249deae29 100644
--- a/plugins/dummy/gs-plugin-dummy.c
+++ b/plugins/dummy/gs-plugin-dummy.c
@@ -57,6 +57,7 @@ gs_plugin_initialize (GsPlugin *plugin)
        priv->cached_origin = gs_app_new (gs_plugin_get_name (plugin));
        gs_app_set_kind (priv->cached_origin, AS_COMPONENT_KIND_REPOSITORY);
        gs_app_set_origin_hostname (priv->cached_origin, "http://www.bbc.co.uk/";);
+       gs_app_set_management_plugin (priv->cached_origin, gs_plugin_get_name (plugin));
 
        /* add the source to the plugin cache which allows us to match the
         * unique ID to a GsApp when creating an event */
diff --git a/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c 
b/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c
index e77665991..78b293fe8 100644
--- a/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c
+++ b/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c
@@ -157,6 +157,7 @@ gs_plugin_setup (GsPlugin *plugin, GCancellable *cancellable, GError **error)
        gs_app_set_kind (priv->cached_origin, AS_COMPONENT_KIND_REPOSITORY);
        gs_app_set_origin_hostname (priv->cached_origin,
                                    FEDORA_PKGDB_COLLECTIONS_API_URI);
+       gs_app_set_management_plugin (priv->cached_origin, gs_plugin_get_name (plugin));
 
        /* add the source to the plugin cache which allows us to match the
         * unique ID to a GsApp when creating an event */
diff --git a/plugins/flatpak/gs-flatpak-utils.c b/plugins/flatpak/gs-flatpak-utils.c
index af2af9141..3882583c8 100644
--- a/plugins/flatpak/gs-flatpak-utils.c
+++ b/plugins/flatpak/gs-flatpak-utils.c
@@ -76,6 +76,7 @@ gs_flatpak_app_new_from_remote (FlatpakRemote *xremote)
        gs_app_set_name (app, GS_APP_QUALITY_LOWEST,
                         flatpak_remote_get_name (xremote));
        gs_app_set_size_download (app, GS_APP_SIZE_UNKNOWABLE);
+       gs_app_set_management_plugin (app, gs_plugin_get_name (plugin));
 
        /* title */
        title = flatpak_remote_get_title (xremote);
diff --git a/plugins/fwupd/gs-plugin-fwupd.c b/plugins/fwupd/gs-plugin-fwupd.c
index 4ddd77037..af3897329 100644
--- a/plugins/fwupd/gs-plugin-fwupd.c
+++ b/plugins/fwupd/gs-plugin-fwupd.c
@@ -248,6 +248,7 @@ gs_plugin_setup (GsPlugin *plugin, GCancellable *cancellable, GError **error)
        priv->cached_origin = gs_app_new (gs_plugin_get_name (plugin));
        gs_app_set_kind (priv->cached_origin, AS_COMPONENT_KIND_REPOSITORY);
        gs_app_set_bundle_kind (priv->cached_origin, AS_BUNDLE_KIND_CABINET);
+       gs_app_set_management_plugin (priv->cached_origin, gs_plugin_get_name (plugin));
 
        /* add the source to the plugin cache which allows us to match the
         * unique ID to a GsApp when creating an event */


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