[gnome-software] Only call the GsPage installed and removed vfuncs of the app changed state
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] Only call the GsPage installed and removed vfuncs of the app changed state
- Date: Wed, 23 Nov 2016 14:21:40 +0000 (UTC)
commit 3ae0bef8df738af320655efc8d167e244989ff40
Author: Richard Hughes <richard hughsie com>
Date: Wed Nov 23 14:13:39 2016 +0000
Only call the GsPage installed and removed vfuncs of the app changed state
src/gs-page.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/src/gs-page.c b/src/gs-page.c
index d0c7b27..5c21b0a 100644
--- a/src/gs-page.c
+++ b/src/gs-page.c
@@ -178,8 +178,10 @@ gs_page_app_installed_cb (GObject *source,
!gs_shell_is_active (priv->shell))
gs_app_notify_installed (helper->app);
- if (GS_PAGE_GET_CLASS (page)->app_installed != NULL)
+ if (gs_app_is_installed (helper->app) &&
+ GS_PAGE_GET_CLASS (page)->app_installed != NULL) {
GS_PAGE_GET_CLASS (page)->app_installed (page, helper->app);
+ }
}
static void
@@ -229,8 +231,10 @@ gs_page_app_removed_cb (GObject *source,
return;
}
- if (GS_PAGE_GET_CLASS (page)->app_removed != NULL)
+ if (!gs_app_is_installed (helper->app) &&
+ GS_PAGE_GET_CLASS (page)->app_removed != NULL) {
GS_PAGE_GET_CLASS (page)->app_removed (page, helper->app);
+ }
}
GtkWidget *
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]