[gnome-software] packagekit refresh: Don't implement gs_plugin_update
- From: Kalev Lember <klember src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] packagekit refresh: Don't implement gs_plugin_update
- Date: Wed, 24 Oct 2018 09:58:31 +0000 (UTC)
commit 09395ae6e028ec8783d9d3b97b47e5ce2cfc69ff
Author: Kalev Lember <klember redhat com>
Date: Thu Oct 11 09:29:02 2018 +0200
packagekit refresh: Don't implement gs_plugin_update
With the new autoupdates we are supposed to have three separate actions:
refresh, download, and update. In the packagekit plugin, download and
update were however all mangled up, so that in the update vfunc it first
tried to download things, and then kick off a system update.
This commit fixes it by removing the update downloading in
gs_plugin_update() and only leaves offline update triggering there,
giving more control to the frontend for scheduling things.
plugins/packagekit/gs-plugin-packagekit-refresh.c | 28 ++++-------------------
1 file changed, 5 insertions(+), 23 deletions(-)
---
diff --git a/plugins/packagekit/gs-plugin-packagekit-refresh.c
b/plugins/packagekit/gs-plugin-packagekit-refresh.c
index 2b8ce27c..e62b20df 100644
--- a/plugins/packagekit/gs-plugin-packagekit-refresh.c
+++ b/plugins/packagekit/gs-plugin-packagekit-refresh.c
@@ -104,11 +104,11 @@ _download_only (GsPlugin *plugin, GsAppList *list,
return TRUE;
}
-static gboolean
-gs_plugin_packagekit_download (GsPlugin *plugin,
- GsAppList *list,
- GCancellable *cancellable,
- GError **error)
+gboolean
+gs_plugin_download (GsPlugin *plugin,
+ GsAppList *list,
+ GCancellable *cancellable,
+ GError **error)
{
g_autoptr(GsAppList) list_tmp = gs_app_list_new ();
@@ -128,24 +128,6 @@ gs_plugin_packagekit_download (GsPlugin *plugin,
return TRUE;
}
-gboolean
-gs_plugin_download (GsPlugin *plugin,
- GsAppList *list,
- GCancellable *cancellable,
- GError **error)
-{
- return gs_plugin_packagekit_download (plugin, list, cancellable, error);
-}
-
-gboolean
-gs_plugin_update (GsPlugin *plugin,
- GsAppList *list,
- GCancellable *cancellable,
- GError **error)
-{
- return gs_plugin_packagekit_download (plugin, list, cancellable, error);
-}
-
gboolean
gs_plugin_refresh (GsPlugin *plugin,
guint cache_age,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]