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

Unified Diff: ash/display/unified_mouse_warp_controller_unittest.cc

Issue 2355063002: Separate ash::test::DisplayManagerTestApi from ash (Closed)
Patch Set: review comment Created 4 years, 2 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 | « ash/display/unified_mouse_warp_controller.h ('k') | ash/display/window_tree_host_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/display/unified_mouse_warp_controller_unittest.cc
diff --git a/ash/display/unified_mouse_warp_controller_unittest.cc b/ash/display/unified_mouse_warp_controller_unittest.cc
index 544f8a2b6c231f80ad9dee0cca1e1775d081765c..74842b1801c5e06e8131766c440bb4d665d72aef 100644
--- a/ash/display/unified_mouse_warp_controller_unittest.cc
+++ b/ash/display/unified_mouse_warp_controller_unittest.cc
@@ -29,7 +29,7 @@ class UnifiedMouseWarpControllerTest : public test::AshTestBase {
void SetUp() override {
test::AshTestBase::SetUp();
- Shell::GetInstance()->display_manager()->SetUnifiedDesktopEnabled(true);
+ display_manager()->SetUnifiedDesktopEnabled(true);
}
protected:
@@ -38,10 +38,9 @@ class UnifiedMouseWarpControllerTest : public test::AshTestBase {
int64_t* display_id,
gfx::Point* point_in_mirroring_host,
gfx::Point* point_in_unified_host) {
- DisplayManager* display_manager = Shell::GetInstance()->display_manager();
- for (auto display : display_manager->software_mirroring_display_list()) {
+ for (auto display : display_manager()->software_mirroring_display_list()) {
display::ManagedDisplayInfo info =
- display_manager->GetDisplayInfo(display.id());
+ display_manager()->GetDisplayInfo(display.id());
if (info.bounds_in_native().Contains(point_in_native)) {
*display_id = info.id();
*point_in_unified_host = point_in_native;
@@ -69,7 +68,6 @@ class UnifiedMouseWarpControllerTest : public test::AshTestBase {
->mouse_cursor_filter()
->mouse_warp_controller_for_test())
->update_location_for_test();
- DisplayManager* display_manager = Shell::GetInstance()->display_manager();
int64_t orig_mirroring_display_id;
gfx::Point point_in_unified_host;
gfx::Point point_in_mirroring_host;
@@ -93,12 +91,12 @@ class UnifiedMouseWarpControllerTest : public test::AshTestBase {
root->GetHost()->ConvertPointToHost(&new_location_in_unified_host);
int new_index = display::FindDisplayIndexContainingPoint(
- display_manager->software_mirroring_display_list(),
+ display_manager()->software_mirroring_display_list(),
new_location_in_unified_host);
if (new_index < 0)
return false;
return orig_mirroring_display_id !=
- display_manager->software_mirroring_display_list()[new_index].id();
+ display_manager()->software_mirroring_display_list()[new_index].id();
}
MouseCursorEventFilter* event_filter() {
« no previous file with comments | « ash/display/unified_mouse_warp_controller.h ('k') | ash/display/window_tree_host_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698