[gnome-software/1364-implement-other-apps-by-author-section-in-app-details-page: 209/215] gs-plugin-appstream: Implement search for developer apps
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/1364-implement-other-apps-by-author-section-in-app-details-page: 209/215] gs-plugin-appstream: Implement search for developer apps
- Date: Mon, 30 May 2022 09:50:39 +0000 (UTC)
commit 25b621299599adc93522cfddd73f4711af587cc8
Author: Milan Crha <mcrha redhat com>
Date: Fri May 6 10:36:04 2022 +0200
gs-plugin-appstream: Implement search for developer apps
plugins/core/gs-plugin-appstream.c | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
---
diff --git a/plugins/core/gs-plugin-appstream.c b/plugins/core/gs-plugin-appstream.c
index 2779492b6..7755a177b 100644
--- a/plugins/core/gs-plugin-appstream.c
+++ b/plugins/core/gs-plugin-appstream.c
@@ -1418,6 +1418,7 @@ list_apps_thread_cb (GTask *task,
GsAppQueryTristate is_installed = GS_APP_QUERY_TRISTATE_UNSET;
guint64 age_secs = 0;
const gchar * const *deployment_featured = NULL;
+ const gchar * const *developers = NULL;
g_autoptr(GError) local_error = NULL;
assert_in_worker (self);
@@ -1429,6 +1430,7 @@ list_apps_thread_cb (GTask *task,
category = gs_app_query_get_category (data->query);
is_installed = gs_app_query_get_is_installed (data->query);
deployment_featured = gs_app_query_get_deployment_featured (data->query);
+ developers = gs_app_query_get_developers (data->query);
}
if (released_since != NULL) {
g_autoptr(GDateTime) now = g_date_time_new_now_utc ();
@@ -1442,7 +1444,8 @@ list_apps_thread_cb (GTask *task,
is_featured == GS_APP_QUERY_TRISTATE_UNSET &&
category == NULL &&
is_installed == GS_APP_QUERY_TRISTATE_UNSET &&
- deployment_featured == NULL) ||
+ deployment_featured == NULL &&
+ developers == NULL) ||
is_curated == GS_APP_QUERY_TRISTATE_FALSE ||
is_featured == GS_APP_QUERY_TRISTATE_FALSE ||
is_installed == GS_APP_QUERY_TRISTATE_FALSE ||
@@ -1498,6 +1501,12 @@ list_apps_thread_cb (GTask *task,
return;
}
+ if (developers != NULL &&
+ !gs_appstream_search_developer_apps (GS_PLUGIN (self), self->silo, developers, list, cancellable,
&local_error)) {
+ g_task_return_error (task, g_steal_pointer (&local_error));
+ return;
+ }
+
g_task_return_pointer (task, g_steal_pointer (&list), g_object_unref);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]