| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/app_list_page.h" | 5 #include "ui/app_list/views/app_list_page.h" |
| 6 | 6 |
| 7 #include "ui/app_list/views/contents_view.h" | 7 #include "ui/app_list/views/contents_view.h" |
| 8 | 8 |
| 9 namespace { | 9 namespace { |
| 10 | 10 |
| 11 // The default z height for the search box. | 11 // The default z height for the search box. |
| 12 const int kDefaultSearchBoxZHeight = 2; | 12 const int kDefaultSearchBoxZHeight = 2; |
| 13 } | 13 } // namespace |
| 14 | 14 |
| 15 namespace app_list { | 15 namespace app_list { |
| 16 | 16 |
| 17 AppListPage::AppListPage() : contents_view_(nullptr) { | 17 AppListPage::AppListPage() : contents_view_(nullptr) {} |
| 18 } | |
| 19 | 18 |
| 20 AppListPage::~AppListPage() { | 19 AppListPage::~AppListPage() {} |
| 21 } | |
| 22 | 20 |
| 23 void AppListPage::OnShown() { | 21 void AppListPage::OnShown() {} |
| 24 } | |
| 25 | 22 |
| 26 void AppListPage::OnWillBeShown() { | 23 void AppListPage::OnWillBeShown() {} |
| 27 } | |
| 28 | 24 |
| 29 void AppListPage::OnHidden() { | 25 void AppListPage::OnHidden() {} |
| 30 } | |
| 31 | 26 |
| 32 void AppListPage::OnWillBeHidden() { | 27 void AppListPage::OnWillBeHidden() {} |
| 33 } | |
| 34 | 28 |
| 35 void AppListPage::OnAnimationUpdated(double progress, | 29 void AppListPage::OnAnimationUpdated(double progress, |
| 36 AppListModel::State from_state, | 30 AppListModel::State from_state, |
| 37 AppListModel::State to_state) { | 31 AppListModel::State to_state) {} |
| 38 } | |
| 39 | 32 |
| 40 gfx::Rect AppListPage::GetSearchBoxBounds() const { | 33 gfx::Rect AppListPage::GetSearchBoxBounds() const { |
| 41 DCHECK(contents_view_); | 34 DCHECK(contents_view_); |
| 42 return contents_view_->GetDefaultSearchBoxBounds(); | 35 return contents_view_->GetDefaultSearchBoxBounds(); |
| 43 } | 36 } |
| 44 | 37 |
| 45 int AppListPage::GetSearchBoxZHeight() const { | 38 int AppListPage::GetSearchBoxZHeight() const { |
| 46 return kDefaultSearchBoxZHeight; | 39 return kDefaultSearchBoxZHeight; |
| 47 } | 40 } |
| 48 | 41 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 64 gfx::Rect AppListPage::GetFullContentsBounds() const { | 57 gfx::Rect AppListPage::GetFullContentsBounds() const { |
| 65 DCHECK(contents_view_); | 58 DCHECK(contents_view_); |
| 66 return contents_view_->GetContentsBounds(); | 59 return contents_view_->GetContentsBounds(); |
| 67 } | 60 } |
| 68 | 61 |
| 69 gfx::Rect AppListPage::GetDefaultContentsBounds() const { | 62 gfx::Rect AppListPage::GetDefaultContentsBounds() const { |
| 70 DCHECK(contents_view_); | 63 DCHECK(contents_view_); |
| 71 return contents_view_->GetDefaultContentsBounds(); | 64 return contents_view_->GetDefaultContentsBounds(); |
| 72 } | 65 } |
| 73 | 66 |
| 67 bool AppListPage::IsCustomLauncherPageActive() const { |
| 68 return contents_view_->IsStateActive( |
| 69 AppListModel::STATE_CUSTOM_LAUNCHER_PAGE); |
| 70 } |
| 71 |
| 74 } // namespace app_list | 72 } // namespace app_list |
| OLD | NEW |