| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/presenter/app_list.h" | 5 #include "ui/app_list/presenter/app_list.h" |
| 6 | 6 |
| 7 #include "ui/app_list/presenter/app_list_delegate.h" |
| 8 |
| 7 namespace app_list { | 9 namespace app_list { |
| 8 | 10 |
| 9 AppList::AppList() {} | 11 AppList::AppList() {} |
| 10 | 12 |
| 11 AppList::~AppList() {} | 13 AppList::~AppList() {} |
| 12 | 14 |
| 13 void AppList::BindRequest(mojom::AppListRequest request) { | 15 void AppList::BindRequest(mojom::AppListRequest request) { |
| 14 bindings_.AddBinding(this, std::move(request)); | 16 bindings_.AddBinding(this, std::move(request)); |
| 15 } | 17 } |
| 16 | 18 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 42 } | 44 } |
| 43 | 45 |
| 44 void AppList::SetAppListPresenter(mojom::AppListPresenterPtr presenter) { | 46 void AppList::SetAppListPresenter(mojom::AppListPresenterPtr presenter) { |
| 45 presenter_ = std::move(presenter); | 47 presenter_ = std::move(presenter); |
| 46 } | 48 } |
| 47 | 49 |
| 48 void AppList::OnTargetVisibilityChanged(bool visible) { | 50 void AppList::OnTargetVisibilityChanged(bool visible) { |
| 49 target_visible_ = visible; | 51 target_visible_ = visible; |
| 50 } | 52 } |
| 51 | 53 |
| 52 void AppList::OnVisibilityChanged(bool visible) { | 54 void AppList::OnVisibilityChanged(bool visible, int64_t display_id) { |
| 55 if (visible_ == visible) |
| 56 return; |
| 57 |
| 53 visible_ = visible; | 58 visible_ = visible; |
| 59 if (delegate_) |
| 60 delegate_->OnAppListVisibilityChanged(visible, display_id); |
| 54 } | 61 } |
| 55 | 62 |
| 56 } // namespace app_list | 63 } // namespace app_list |
| OLD | NEW |