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

Side by Side Diff: ui/app_list/views/apps_grid_view.cc

Issue 395653005: Stop app list folder animation from hiding item text label. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 5 months 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 unified diff | Download patch
« no previous file with comments | « ui/app_list/views/app_list_item_view.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/app_list/views/apps_grid_view.h" 5 #include "ui/app_list/views/apps_grid_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 10
(...skipping 717 matching lines...) Expand 10 before | Expand all | Expand 10 after
728 728
729 AppListItemView* AppsGridView::GetItemViewAt(int index) const { 729 AppListItemView* AppsGridView::GetItemViewAt(int index) const {
730 DCHECK(index >= 0 && index < view_model_.view_size()); 730 DCHECK(index >= 0 && index < view_model_.view_size());
731 return static_cast<AppListItemView*>(view_model_.view_at(index)); 731 return static_cast<AppListItemView*>(view_model_.view_at(index));
732 } 732 }
733 733
734 void AppsGridView::SetTopItemViewsVisible(bool visible) { 734 void AppsGridView::SetTopItemViewsVisible(bool visible) {
735 int top_item_count = std::min(static_cast<int>(kNumFolderTopItems), 735 int top_item_count = std::min(static_cast<int>(kNumFolderTopItems),
736 view_model_.view_size()); 736 view_model_.view_size());
737 for (int i = 0; i < top_item_count; ++i) 737 for (int i = 0; i < top_item_count; ++i)
738 GetItemViewAt(i)->SetVisible(visible); 738 GetItemViewAt(i)->icon()->SetVisible(visible);
739 } 739 }
740 740
741 void AppsGridView::ScheduleShowHideAnimation(bool show) { 741 void AppsGridView::ScheduleShowHideAnimation(bool show) {
742 // Stop any previous animation. 742 // Stop any previous animation.
743 layer()->GetAnimator()->StopAnimating(); 743 layer()->GetAnimator()->StopAnimating();
744 744
745 // Set initial state. 745 // Set initial state.
746 SetVisible(true); 746 SetVisible(true);
747 layer()->SetOpacity(show ? 0.0f : 1.0f); 747 layer()->SetOpacity(show ? 0.0f : 1.0f);
748 748
(...skipping 1413 matching lines...) Expand 10 before | Expand all | Expand 10 after
2162 void AppsGridView::SetAsFolderDroppingTarget(const Index& target_index, 2162 void AppsGridView::SetAsFolderDroppingTarget(const Index& target_index,
2163 bool is_target_folder) { 2163 bool is_target_folder) {
2164 AppListItemView* target_view = 2164 AppListItemView* target_view =
2165 static_cast<AppListItemView*>( 2165 static_cast<AppListItemView*>(
2166 GetViewAtSlotOnCurrentPage(target_index.slot)); 2166 GetViewAtSlotOnCurrentPage(target_index.slot));
2167 if (target_view) 2167 if (target_view)
2168 target_view->SetAsAttemptedFolderTarget(is_target_folder); 2168 target_view->SetAsAttemptedFolderTarget(is_target_folder);
2169 } 2169 }
2170 2170
2171 } // namespace app_list 2171 } // namespace app_list
OLDNEW
« no previous file with comments | « ui/app_list/views/app_list_item_view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698