Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(359)

Unified Diff: ui/app_list/views/apps_grid_view.cc

Issue 59623005: app_list: Fix sync animation crash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/views/apps_grid_view.cc
diff --git a/ui/app_list/views/apps_grid_view.cc b/ui/app_list/views/apps_grid_view.cc
index d8f92c305ada4b7812851763baae3357477a32f2..f300de7fdd22400d750c8f6a4fe52b28ce640eae 100644
--- a/ui/app_list/views/apps_grid_view.cc
+++ b/ui/app_list/views/apps_grid_view.cc
@@ -657,8 +657,9 @@ void AppsGridView::UpdatePaging() {
}
void AppsGridView::UpdatePulsingBlockViews() {
+ const int existing_items = item_list_ ? item_list_->item_count() : 0;
const int available_slots =
- tiles_per_page() - item_list_->item_count() % tiles_per_page();
+ tiles_per_page() - existing_items % tiles_per_page();
const int desired = model_->status() == AppListModel::STATUS_SYNCING ?
available_slots : 0;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698