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 "ash/common/shelf/shelf_delegate.h" | 5 #include "ash/common/shelf/shelf_delegate.h" |
6 #include "ash/common/wm_shell.h" | 6 #include "ash/common/wm_shell.h" |
7 #include "ash/wm/window_util.h" | 7 #include "ash/wm/window_util.h" |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "base/run_loop.h" | 9 #include "base/run_loop.h" |
10 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
11 #include "chrome/browser/extensions/extension_browsertest.h" | 11 #include "chrome/browser/extensions/extension_browsertest.h" |
12 #include "chrome/browser/ui/app_list/app_list_service.h" | 12 #include "chrome/browser/ui/app_list/app_list_service.h" |
13 #include "chrome/browser/ui/app_list/app_list_syncable_service.h" | 13 #include "chrome/browser/ui/app_list/app_list_syncable_service.h" |
14 #include "chrome/browser/ui/app_list/app_list_syncable_service_factory.h" | 14 #include "chrome/browser/ui/app_list/app_list_syncable_service_factory.h" |
15 #include "chrome/browser/ui/app_list/arc/arc_app_list_prefs.h" | 15 #include "chrome/browser/ui/app_list/arc/arc_app_list_prefs.h" |
16 #include "chrome/browser/ui/app_list/arc/arc_app_utils.h" | 16 #include "chrome/browser/ui/app_list/arc/arc_app_utils.h" |
17 #include "chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.h" | 17 #include "chrome/browser/ui/ash/launcher/arc_app_deferred_launcher_controller.h" |
18 #include "chrome/browser/ui/ash/launcher/arc_app_window_launcher_controller.h" | 18 #include "chrome/browser/ui/ash/launcher/arc_app_window_launcher_controller.h" |
19 #include "chrome/browser/ui/ash/launcher/chrome_launcher_controller.h" | 19 #include "chrome/browser/ui/ash/launcher/chrome_launcher_controller.h" |
20 #include "chrome/browser/ui/ash/launcher/launcher_item_controller.h" | 20 #include "chrome/browser/ui/ash/launcher/launcher_item_controller.h" |
21 #include "chromeos/chromeos_switches.h" | 21 #include "chromeos/chromeos_switches.h" |
22 #include "content/public/test/browser_test_utils.h" | 22 #include "content/public/test/browser_test_utils.h" |
23 #include "mojo/common/common_type_converters.h" | |
24 #include "ui/events/event_constants.h" | 23 #include "ui/events/event_constants.h" |
25 | 24 |
26 namespace mojo { | 25 namespace mojo { |
27 | 26 |
28 template <> | 27 template <> |
29 struct TypeConverter<arc::mojom::AppInfoPtr, arc::mojom::AppInfo> { | 28 struct TypeConverter<arc::mojom::AppInfoPtr, arc::mojom::AppInfo> { |
30 static arc::mojom::AppInfoPtr Convert(const arc::mojom::AppInfo& app_info) { | 29 static arc::mojom::AppInfoPtr Convert(const arc::mojom::AppInfo& app_info) { |
31 return app_info.Clone(); | 30 return app_info.Clone(); |
32 } | 31 } |
33 }; | 32 }; |
(...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
535 app_host()->OnTaskDestroyed(2); | 534 app_host()->OnTaskDestroyed(2); |
536 EXPECT_EQ(controller2, GetAppItemController(shelf_id2)); | 535 EXPECT_EQ(controller2, GetAppItemController(shelf_id2)); |
537 // Destroy task #2, this kills shelf group 2 | 536 // Destroy task #2, this kills shelf group 2 |
538 app_host()->OnTaskDestroyed(3); | 537 app_host()->OnTaskDestroyed(3); |
539 EXPECT_FALSE(GetAppItemController(shelf_id2)); | 538 EXPECT_FALSE(GetAppItemController(shelf_id2)); |
540 | 539 |
541 // Disable Arc, this removes app and as result kills shelf group 3. | 540 // Disable Arc, this removes app and as result kills shelf group 3. |
542 arc::ArcSessionManager::Get()->DisableArc(); | 541 arc::ArcSessionManager::Get()->DisableArc(); |
543 EXPECT_FALSE(GetAppItemController(shelf_id3)); | 542 EXPECT_FALSE(GetAppItemController(shelf_id3)); |
544 } | 543 } |
OLD | NEW |