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

Unified Diff: ash/display/resolution_notification_controller_unittest.cc

Issue 138003007: [Cleanup] Screen cleanup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: make sure screen_for_shutdown is reset everytime Created 6 years, 11 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/mouse_cursor_event_filter.cc ('k') | ash/display/root_window_transformers_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/display/resolution_notification_controller_unittest.cc
diff --git a/ash/display/resolution_notification_controller_unittest.cc b/ash/display/resolution_notification_controller_unittest.cc
index 0ec8852df05fa27486c920319b0adb069ccabbfc..e167c61848ef4008322f2399b02fe8d1be0b9522 100644
--- a/ash/display/resolution_notification_controller_unittest.cc
+++ b/ash/display/resolution_notification_controller_unittest.cc
@@ -5,7 +5,7 @@
#include "ash/display/resolution_notification_controller.h"
#include "ash/display/display_manager.h"
-#include "ash/screen_ash.h"
+#include "ash/screen_util.h"
#include "ash/shell.h"
#include "ash/test/ash_test_base.h"
#include "base/bind.h"
@@ -107,7 +107,7 @@ TEST_F(ResolutionNotificationControllerTest, Basic) {
return;
UpdateDisplay("300x300#300x300|200x200,250x250#250x250|200x200");
- int64 id2 = ash::ScreenAsh::GetSecondaryDisplay().id();
+ int64 id2 = ash::ScreenUtil::GetSecondaryDisplay().id();
ash::internal::DisplayManager* display_manager =
ash::Shell::GetInstance()->display_manager();
ASSERT_EQ(0, accept_count());
@@ -115,7 +115,7 @@ TEST_F(ResolutionNotificationControllerTest, Basic) {
// Changes the resolution and apply the result.
SetDisplayResolutionAndNotify(
- ScreenAsh::GetSecondaryDisplay(), gfx::Size(200, 200));
+ ScreenUtil::GetSecondaryDisplay(), gfx::Size(200, 200));
EXPECT_TRUE(IsNotificationVisible());
EXPECT_FALSE(controller()->DoesNotificationTimeout());
gfx::Size resolution;
@@ -137,7 +137,7 @@ TEST_F(ResolutionNotificationControllerTest, ClickMeansAccept) {
return;
UpdateDisplay("300x300#300x300|200x200,250x250#250x250|200x200");
- int64 id2 = ash::ScreenAsh::GetSecondaryDisplay().id();
+ int64 id2 = ash::ScreenUtil::GetSecondaryDisplay().id();
ash::internal::DisplayManager* display_manager =
ash::Shell::GetInstance()->display_manager();
ASSERT_EQ(0, accept_count());
@@ -145,7 +145,7 @@ TEST_F(ResolutionNotificationControllerTest, ClickMeansAccept) {
// Changes the resolution and apply the result.
SetDisplayResolutionAndNotify(
- ScreenAsh::GetSecondaryDisplay(), gfx::Size(200, 200));
+ ScreenUtil::GetSecondaryDisplay(), gfx::Size(200, 200));
EXPECT_TRUE(IsNotificationVisible());
EXPECT_FALSE(controller()->DoesNotificationTimeout());
gfx::Size resolution;
@@ -204,7 +204,7 @@ TEST_F(ResolutionNotificationControllerTest, Close) {
return;
UpdateDisplay("100x100,150x150#150x150|200x200");
- int64 id2 = ash::ScreenAsh::GetSecondaryDisplay().id();
+ int64 id2 = ash::ScreenUtil::GetSecondaryDisplay().id();
ash::internal::DisplayManager* display_manager =
ash::Shell::GetInstance()->display_manager();
ASSERT_EQ(0, accept_count());
@@ -212,7 +212,7 @@ TEST_F(ResolutionNotificationControllerTest, Close) {
// Changes the resolution and apply the result.
SetDisplayResolutionAndNotify(
- ScreenAsh::GetSecondaryDisplay(), gfx::Size(200, 200));
+ ScreenUtil::GetSecondaryDisplay(), gfx::Size(200, 200));
EXPECT_TRUE(IsNotificationVisible());
EXPECT_FALSE(controller()->DoesNotificationTimeout());
gfx::Size resolution;
@@ -256,11 +256,11 @@ TEST_F(ResolutionNotificationControllerTest, DisplayDisconnected) {
return;
UpdateDisplay("300x300#300x300|200x200,200x200#250x250|200x200|100x100");
- int64 id2 = ash::ScreenAsh::GetSecondaryDisplay().id();
+ int64 id2 = ash::ScreenUtil::GetSecondaryDisplay().id();
ash::internal::DisplayManager* display_manager =
ash::Shell::GetInstance()->display_manager();
SetDisplayResolutionAndNotify(
- ScreenAsh::GetSecondaryDisplay(), gfx::Size(100, 100));
+ ScreenUtil::GetSecondaryDisplay(), gfx::Size(100, 100));
ASSERT_TRUE(IsNotificationVisible());
// Disconnects the secondary display and verifies it doesn't cause crashes.
@@ -279,12 +279,12 @@ TEST_F(ResolutionNotificationControllerTest, MultipleResolutionChange) {
return;
UpdateDisplay("300x300#300x300|200x200,250x250#250x250|200x200");
- int64 id2 = ash::ScreenAsh::GetSecondaryDisplay().id();
+ int64 id2 = ash::ScreenUtil::GetSecondaryDisplay().id();
ash::internal::DisplayManager* display_manager =
ash::Shell::GetInstance()->display_manager();
SetDisplayResolutionAndNotify(
- ScreenAsh::GetSecondaryDisplay(), gfx::Size(200, 200));
+ ScreenUtil::GetSecondaryDisplay(), gfx::Size(200, 200));
EXPECT_TRUE(IsNotificationVisible());
EXPECT_FALSE(controller()->DoesNotificationTimeout());
gfx::Size resolution;
@@ -295,7 +295,7 @@ TEST_F(ResolutionNotificationControllerTest, MultipleResolutionChange) {
// Invokes SetDisplayResolutionAndNotify during the previous notification is
// visible.
SetDisplayResolutionAndNotify(
- ScreenAsh::GetSecondaryDisplay(), gfx::Size(250, 250));
+ ScreenUtil::GetSecondaryDisplay(), gfx::Size(250, 250));
EXPECT_FALSE(
display_manager->GetSelectedResolutionForDisplayId(id2, &resolution));
« no previous file with comments | « ash/display/mouse_cursor_event_filter.cc ('k') | ash/display/root_window_transformers_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698