Commit 11ebd55e authored by oshima@chromium.org's avatar oshima@chromium.org

consolidate DISABLED macros in mouse_cursor_event_filter_unittests.cc

Include sequence number in RootWindow's name so that we can tell in which root window a window is in.

BUG=none
TEST=none

Review URL: https://chromiumcodereview.appspot.com/11825015

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175908 0039d316-1c4b-4281-b951-d872f2087c98
parent 4c3d9d6a
......@@ -320,10 +320,14 @@ void DisplayManager::UpdateDisplays(
RootWindow* DisplayManager::CreateRootWindowForDisplay(
const gfx::Display& display) {
static int root_window_count = 0;
RootWindow::CreateParams params(display.bounds_in_pixel());
params.host = Shell::GetInstance()->root_window_host_factory()->
CreateRootWindowHost(display.bounds_in_pixel());
aura::RootWindow* root_window = new aura::RootWindow(params);
root_window->SetName(StringPrintf("RootWindow-%d", root_window_count++));
// No need to remove RootWindowObserver because
// the DisplayManager object outlives RootWindow objects.
root_window->AddRootWindowObserver(this);
......
......@@ -35,8 +35,18 @@ typedef test::AshTestBase MouseCursorEventFilterTest;
#if defined(OS_WIN)
// Multiple displays are not supported on Windows Ash. http://crbug.com/165962
#define MAYBE_WarpMouse DISABLED_WarpMouse
#define MAYBE_CursorDeviceScaleFactor DISABLED_CursorDeviceScaleFactor
#define MAYBE_WarpMouseDifferentSizeDisplays \
DISABLED_WarpMouseDifferentSizeDisplays
#define MAYBE_WarpMouseDifferentScaleDisplays \
DISABLED_WarpMouseDifferentScaleDisplays
#define MAYBE_SetMouseWarpModeFlag DISABLED_SetMouseWarpModeFlag
#else
#define MAYBE_WarpMouse WarpMouse
#define MAYBE_CursorDeviceScaleFactor CursorDeviceScaleFactor
#define MAYBE_WarpMouseDifferentSizeDisplays WarpMouseDifferentSizeDisplays
#define MAYBE_WarpMouseDifferentScaleDisplays WarpMouseDifferentScaleDisplays
#define MAYBE_SetMouseWarpModeFlag SetMouseWarpModeFlag
#endif
// Verifies if the mouse pointer correctly moves to another display when there
......@@ -100,14 +110,6 @@ TEST_F(MouseCursorEventFilterTest, MAYBE_WarpMouse) {
}
#if defined(OS_WIN)
// Multiple displays are not supported on Windows Ash. http://crbug.com/165962
#define MAYBE_WarpMouseDifferentSizeDisplays \
DISABLED_WarpMouseDifferentSizeDisplays
#else
#define MAYBE_WarpMouseDifferentSizeDisplays WarpMouseDifferentSizeDisplays
#endif
// Verifies if the mouse pointer correctly moves to another display even when
// two displays are not the same size.
TEST_F(MouseCursorEventFilterTest, MAYBE_WarpMouseDifferentSizeDisplays) {
......@@ -140,14 +142,6 @@ TEST_F(MouseCursorEventFilterTest, MAYBE_WarpMouseDifferentSizeDisplays) {
aura::Env::GetInstance()->last_mouse_location().ToString());
}
#if defined(OS_WIN)
// Multiple displays are not supported on Windows Ash. http://crbug.com/165962
#define MAYBE_WarpMouseDifferentScaleDisplays \
DISABLED_WarpMouseDifferentScaleDisplays
#else
#define MAYBE_WarpMouseDifferentScaleDisplays WarpMouseDifferentScaleDisplays
#endif
// Verifies if the mouse pointer correctly moves between displays with
// different scale factors.
TEST_F(MouseCursorEventFilterTest, MAYBE_WarpMouseDifferentScaleDisplays) {
......@@ -182,13 +176,6 @@ TEST_F(MouseCursorEventFilterTest, MAYBE_WarpMouseDifferentScaleDisplays) {
aura::Env::GetInstance()->last_mouse_location().ToString());
}
#if defined(OS_WIN)
// Multiple displays are not supported on Windows Ash. http://crbug.com/165962
#define MAYBE_SetMouseWarpModeFlag DISABLED_SetMouseWarpModeFlag
#else
#define MAYBE_SetMouseWarpModeFlag SetMouseWarpModeFlag
#endif
// Verifies if MouseCursorEventFilter::set_mouse_warp_mode() works as expected.
TEST_F(MouseCursorEventFilterTest, MAYBE_SetMouseWarpModeFlag) {
UpdateDisplay("500x500,500x500");
......@@ -338,13 +325,6 @@ TEST_F(MouseCursorEventFilterTest, IndicatorBoundsTestOnTopBottom) {
}
#if defined(OS_WIN)
// Multiple displays are not supported on Windows Ash. http://crbug.com/165962
#define MAYBE_CursorDeviceScaleFactor DISABLED_CursorDeviceScaleFactor
#else
#define MAYBE_CursorDeviceScaleFactor CursorDeviceScaleFactor
#endif
// Verifies cursor's device scale factor is updated when a cursor has moved
// across root windows with different device scale factors
// (http://crbug.com/154183).
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment