Index: ash/display/mouse_cursor_event_filter.h |
diff --git a/ash/display/mouse_cursor_event_filter.h b/ash/display/mouse_cursor_event_filter.h |
index 3c5304f3475e0668604d699d4145e9745f58b0ef..55de4a613e470482ba7a9b5de0c3a83af9bf3f6b 100644 |
--- a/ash/display/mouse_cursor_event_filter.h |
+++ b/ash/display/mouse_cursor_event_filter.h |
@@ -26,8 +26,6 @@ class SharedDisplayEdgeIndicator; |
class ASH_EXPORT MouseCursorEventFilter : public ui::EventHandler, |
public DisplayController::Observer { |
public: |
- static bool IsMouseWarpInNativeCoordsEnabled(); |
- |
enum MouseWarpMode { |
WARP_ALWAYS, // Always warp the mouse when possible. |
WARP_DRAG, // Used when dragging a window. Top and bottom |
@@ -71,17 +69,26 @@ class ASH_EXPORT MouseCursorEventFilter : public ui::EventHandler, |
FRIEND_TEST_ALL_PREFIXES(DragWindowResizerTest, WarpMousePointer); |
+ // Moves the cursor to the point inside the root that is closest to |
+ // the point_in_screen, which is outside of the root window. |
+ static void MoveCursorTo(aura::Window* root, |
+ const gfx::Point& point_in_screen); |
+ |
// Warps the mouse cursor to an alternate root window when the |
// mouse location in |event|, hits the edge of the event target's root and |
// the mouse cursor is considered to be in an alternate display. |
// Returns true if/ the cursor was moved. |
bool WarpMouseCursorIfNecessary(ui::MouseEvent* event); |
- bool WarpMouseCursorInNativeCoords(const gfx::Point& point_in_native, |
- const gfx::Point& point_in_screen); |
+#if defined(USE_OZONE) |
bool WarpMouseCursorInScreenCoords(aura::Window* target_root, |
const gfx::Point& point_in_screen); |
+#else |
+ bool WarpMouseCursorInNativeCoords(const gfx::Point& point_in_native, |
+ const gfx::Point& point_in_screen); |
+#endif |
+ |
// Update the edge/indicator bounds based on the current |
// display configuration. |
void UpdateHorizontalEdgeBounds(); |