| Index: ash/wm/toplevel_window_event_handler_unittest.cc
|
| diff --git a/ash/wm/toplevel_window_event_handler_unittest.cc b/ash/wm/toplevel_window_event_handler_unittest.cc
|
| index c84f8b3f122fceb1fbfb3738a84915d365a58616..c558f7bbafe6c611abb33465ec988edc934bcfab 100644
|
| --- a/ash/wm/toplevel_window_event_handler_unittest.cc
|
| +++ b/ash/wm/toplevel_window_event_handler_unittest.cc
|
| @@ -14,7 +14,6 @@
|
| #include "ash/wm/resize_shadow.h"
|
| #include "ash/wm/resize_shadow_controller.h"
|
| #include "ash/wm/window_util.h"
|
| -#include "ash/wm/workspace/snap_sizer.h"
|
| #include "ash/wm/workspace_controller.h"
|
| #include "base/basictypes.h"
|
| #include "base/compiler_specific.h"
|
| @@ -390,10 +389,8 @@ TEST_F(ToplevelWindowEventHandlerTest, GestureDrag) {
|
| // Snap right;
|
| {
|
| // Get the expected snapped bounds before snapping.
|
| - internal::SnapSizer sizer(target.get(), location,
|
| - internal::SnapSizer::RIGHT_EDGE,
|
| - internal::SnapSizer::OTHER_INPUT);
|
| - gfx::Rect snapped_bounds = sizer.GetSnapBounds(target->bounds());
|
| + gfx::Rect snapped_bounds = wm::GetSnappedWindowBoundsInParent(
|
| + target.get(), wm::SNAP_RIGHT_EDGE);
|
|
|
| end.Offset(100, 0);
|
| generator.GestureScrollSequence(location, end,
|
| @@ -411,10 +408,8 @@ TEST_F(ToplevelWindowEventHandlerTest, GestureDrag) {
|
| // Snap left.
|
| {
|
| // Get the expected snapped bounds before snapping.
|
| - internal::SnapSizer sizer(target.get(), location,
|
| - internal::SnapSizer::LEFT_EDGE,
|
| - internal::SnapSizer::OTHER_INPUT);
|
| - gfx::Rect snapped_bounds = sizer.GetSnapBounds(target->bounds());
|
| + gfx::Rect snapped_bounds = wm::GetSnappedWindowBoundsInParent(
|
| + target.get(), wm::SNAP_LEFT_EDGE);
|
| end = location = target->GetBoundsInRootWindow().CenterPoint();
|
| end.Offset(-100, 0);
|
| generator.GestureScrollSequence(location, end,
|
| @@ -530,10 +525,8 @@ TEST_F(ToplevelWindowEventHandlerTest, GestureDragForUnresizableWindow) {
|
| // Try to snap right. The window is not resizable. So it should not snap.
|
| {
|
| // Get the expected snapped bounds before the gesture.
|
| - internal::SnapSizer sizer(target.get(), location,
|
| - internal::SnapSizer::RIGHT_EDGE,
|
| - internal::SnapSizer::OTHER_INPUT);
|
| - gfx::Rect snapped_bounds = sizer.GetSnapBounds(target->bounds());
|
| + gfx::Rect snapped_bounds = wm::GetSnappedWindowBoundsInParent(
|
| + target.get(), wm::SNAP_RIGHT_EDGE);
|
|
|
| end.Offset(100, 0);
|
| generator.GestureScrollSequence(location, end,
|
| @@ -555,10 +548,8 @@ TEST_F(ToplevelWindowEventHandlerTest, GestureDragForUnresizableWindow) {
|
| // Try to snap left. It should not snap.
|
| {
|
| // Get the expected snapped bounds before the gesture.
|
| - internal::SnapSizer sizer(target.get(), location,
|
| - internal::SnapSizer::LEFT_EDGE,
|
| - internal::SnapSizer::OTHER_INPUT);
|
| - gfx::Rect snapped_bounds = sizer.GetSnapBounds(target->bounds());
|
| + gfx::Rect snapped_bounds = wm::GetSnappedWindowBoundsInParent(
|
| + target.get(), wm::SNAP_LEFT_EDGE);
|
| end = location = target->GetBoundsInRootWindow().CenterPoint();
|
| end.Offset(-100, 0);
|
| generator.GestureScrollSequence(location, end,
|
|
|