[gnome-software] installed: Try harder to avoid scheduling more than one reload at a time
- From: Kalev Lember <klember src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] installed: Try harder to avoid scheduling more than one reload at a time
- Date: Mon, 15 Sep 2014 22:12:15 +0000 (UTC)
commit 0a138214e487f490095c1542bea8ee35f99aec76
Author: Kalev Lember <kalevlember gmail com>
Date: Mon Sep 15 23:58:36 2014 +0200
installed: Try harder to avoid scheduling more than one reload at a time
... so that the items in the installed page don't show up twice after
doing an updates refresh.
src/gs-shell-installed.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/gs-shell-installed.c b/src/gs-shell-installed.c
index 46fb5e0..a9cc1b2 100644
--- a/src/gs-shell-installed.c
+++ b/src/gs-shell-installed.c
@@ -298,6 +298,10 @@ gs_shell_installed_load (GsShellInstalled *shell_installed)
{
GsShellInstalledPrivate *priv = shell_installed->priv;
+ if (priv->waiting)
+ return;
+ priv->waiting = TRUE;
+
/* remove old entries */
gs_container_remove_all (GTK_CONTAINER (priv->list_box_install));
@@ -314,8 +318,6 @@ gs_shell_installed_load (GsShellInstalled *shell_installed)
shell_installed);
gs_start_spinner (GTK_SPINNER (priv->spinner_install));
gtk_stack_set_visible_child_name (GTK_STACK (priv->stack_install), "spinner");
-
- priv->waiting = TRUE;
}
/**
@@ -365,8 +367,6 @@ gs_shell_installed_switch_to (GsShellInstalled *shell_installed, gboolean scroll
if (priv->cache_valid)
return;
- if (priv->waiting)
- return;
gs_shell_installed_load (shell_installed);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]