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

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

Issue 907833002: Hide experimental app list Google logo and custom launcher page when search engine is not Google. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@update_app_list_bg_color
Patch Set: address comment, add service dependency Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/app_list/views/contents_view.h ('k') | ui/app_list/views/start_page_view.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/views/contents_view.cc
diff --git a/ui/app_list/views/contents_view.cc b/ui/app_list/views/contents_view.cc
index a076519be2e29ba4b49d041d0db243d5ed2f003a..816ec1311c121aa3f0a08af0bde7a439fc5ed36f 100644
--- a/ui/app_list/views/contents_view.cc
+++ b/ui/app_list/views/contents_view.cc
@@ -183,6 +183,9 @@ int ContentsView::NumLauncherPages() const {
void ContentsView::SetActivePageInternal(int page_index,
bool show_search_results,
bool animate) {
+ if (!GetPageView(page_index)->visible())
+ return;
+
if (!show_search_results)
page_before_search_ = page_index;
// Start animating to the new page.
@@ -414,11 +417,6 @@ gfx::Rect ContentsView::GetCustomPageCollapsedBounds() const {
return bounds;
}
-bool ContentsView::ShouldShowCustomPageClickzone() const {
- return custom_page_view_ && IsStateActive(AppListModel::STATE_START) &&
- app_list_main_view_->model()->custom_launcher_page_enabled();
-}
-
bool ContentsView::Back() {
AppListModel::State state = view_to_state_[GetActivePageIndex()];
switch (state) {
@@ -528,7 +526,7 @@ void ContentsView::SelectedPageChanged(int old_selected, int new_selected) {
// Show or hide the custom page view, based on whether it is enabled.
if (custom_page_view_) {
custom_page_view_->SetVisible(
- app_list_main_view_->model()->custom_launcher_page_enabled());
+ app_list_main_view_->ShouldShowCustomLauncherPage());
}
}
}
« no previous file with comments | « ui/app_list/views/contents_view.h ('k') | ui/app_list/views/start_page_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698