| Index: content/browser/renderer_host/render_widget_host_view_win.h
|
| diff --git a/content/browser/renderer_host/render_widget_host_view_win.h b/content/browser/renderer_host/render_widget_host_view_win.h
|
| index 0f68b427d2637cec8eb498c1605213a506f61529..2ae7c0ba476aa3431bccbf9bb92798898eb0e273 100644
|
| --- a/content/browser/renderer_host/render_widget_host_view_win.h
|
| +++ b/content/browser/renderer_host/render_widget_host_view_win.h
|
| @@ -178,6 +178,8 @@ class RenderWidgetHostViewWin
|
| virtual void OnAccessibilityNotifications(
|
| const std::vector<ViewHostMsg_AccessibilityNotification_Params>& params
|
| ) OVERRIDE;
|
| + virtual bool LockMouse() OVERRIDE;
|
| + virtual void UnlockMouse() OVERRIDE;
|
|
|
| // Implementation of NotificationObserver:
|
| virtual void Observe(int type,
|
| @@ -288,6 +290,11 @@ class RenderWidgetHostViewWin
|
| const gfx::Rect& pos,
|
| DWORD ex_style);
|
|
|
| + CPoint GetClientCenter() const;
|
| + void MoveCursorToCenter() const;
|
| +
|
| + void HandleLockedMouseEvent(UINT message, WPARAM wparam, LPARAM lparam);
|
| +
|
| // The associated Model. While |this| is being Destroyed,
|
| // |render_widget_host_| is NULL and the Windows message loop is run one last
|
| // time. Message handlers must check for a NULL |render_widget_host_|.
|
| @@ -383,6 +390,20 @@ class RenderWidgetHostViewWin
|
| // Is the widget fullscreen?
|
| bool is_fullscreen_;
|
|
|
| + // Used to record the last position of the mouse.
|
| + // While the mouse is locked, they store the last known position just as mouse
|
| + // lock was entered.
|
| + // Relative to the upper-left corner of the view.
|
| + int last_x_;
|
| + int last_y_;
|
| + // Relative to the upper-left corner of the screen.
|
| + int last_global_x_;
|
| + int last_global_y_;
|
| +
|
| + // In the case of the mouse being moved away from the view and then moved
|
| + // back, we regard the mouse movement as (0, 0).
|
| + bool ignore_mouse_movement_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostViewWin);
|
| };
|
|
|
|
|