[gnome-software] Only show the more reviews button more accurately
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] Only show the more reviews button more accurately
- Date: Mon, 28 Nov 2016 09:16:23 +0000 (UTC)
commit 522fc1348329885c9a76837b3d80eb884aa9d0c5
Author: Richard Hughes <richard hughsie com>
Date: Sun Nov 27 21:23:14 2016 +0000
Only show the more reviews button more accurately
src/gs-shell-details.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/gs-shell-details.c b/src/gs-shell-details.c
index a3523eb..858df36 100644
--- a/src/gs-shell-details.c
+++ b/src/gs-shell-details.c
@@ -1256,10 +1256,6 @@ gs_shell_details_refresh_reviews (GsShellDetails *self)
}
}
- /* only show the button if there are more to show */
- gtk_widget_set_visible (self->button_more_reviews,
- n_reviews > SHOW_NR_REVIEWS_INITIAL);
-
/* add all the reviews */
gs_container_remove_all (GTK_CONTAINER (self->list_box_reviews));
reviews = gs_app_get_reviews (self->app);
@@ -1281,6 +1277,10 @@ gs_shell_details_refresh_reviews (GsShellDetails *self)
gtk_widget_set_visible (row, i < SHOW_NR_REVIEWS_INITIAL);
}
+ /* only show the button if there are more to show */
+ gtk_widget_set_visible (self->button_more_reviews,
+ reviews->len > SHOW_NR_REVIEWS_INITIAL);
+
/* show the button only if the user never reviewed */
gtk_widget_set_visible (self->button_review, show_review_button);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]