| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "chrome/browser/ui/app_list/app_list_service_views.h" | 5 #include "chrome/browser/ui/app_list/app_list_service_views.h" |
| 6 | 6 |
| 7 #include "chrome/browser/ui/app_list/app_list_controller_delegate.h" | 7 #include "chrome/browser/ui/app_list/app_list_controller_delegate.h" |
| 8 #include "chrome/browser/ui/app_list/scoped_keep_alive.h" | 8 #include "chrome/browser/ui/app_list/scoped_keep_alive.h" |
| 9 #include "ui/app_list/views/app_list_view.h" | 9 #include "ui/app_list/views/app_list_view.h" |
| 10 | 10 |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 void AppListServiceViews::DestroyAppList() { | 67 void AppListServiceViews::DestroyAppList() { |
| 68 if (!shower_.HasView()) | 68 if (!shower_.HasView()) |
| 69 return; | 69 return; |
| 70 | 70 |
| 71 // Use CloseNow(). This can't be asynchronous because the profile will be | 71 // Use CloseNow(). This can't be asynchronous because the profile will be |
| 72 // deleted once this function returns. | 72 // deleted once this function returns. |
| 73 shower_.app_list()->GetWidget()->CloseNow(); | 73 shower_.app_list()->GetWidget()->CloseNow(); |
| 74 DCHECK(!shower_.HasView()); | 74 DCHECK(!shower_.HasView()); |
| 75 } | 75 } |
| 76 | 76 |
| 77 AppListControllerDelegate* | 77 AppListViewDelegate* AppListServiceViews::GetViewDelegateForCreate() { |
| 78 AppListServiceViews::GetControllerDelegateForCreate() { | 78 return GetViewDelegate(shower_.profile()); |
| 79 return controller_delegate_.get(); | |
| 80 } | 79 } |
| OLD | NEW |