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

Unified Diff: content/renderer/render_view_impl.h

Issue 8970016: refactoring mouse lock to support pepper and WebKit (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Refactor LockTarget interface & Tests Created 8 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
Index: content/renderer/render_view_impl.h
diff --git a/content/renderer/render_view_impl.h b/content/renderer/render_view_impl.h
index 99d3f109ff82a3c11438b2bf2b5142ec13693928..f9f82c73a730f110317ffde40361e1d972b52769 100644
--- a/content/renderer/render_view_impl.h
+++ b/content/renderer/render_view_impl.h
@@ -66,6 +66,7 @@ class JavaBridgeDispatcher;
class LoadProgressTracker;
class MediaStreamDispatcher;
class MediaStreamImpl;
+class MouseLockDispatcher;
class NotificationProvider;
class PepperDeviceTest;
struct PP_NetAddress_Private;
@@ -212,6 +213,10 @@ class RenderViewImpl : public RenderWidget,
return p2p_socket_dispatcher_;
}
+ MouseLockDispatcher* mouse_lock_dispatcher() {
+ return mouse_lock_dispatcher_;
+ }
+
WebKit::WebPeerConnectionHandler* CreatePeerConnectionHandler(
WebKit::WebPeerConnectionHandlerClient* client);
@@ -316,6 +321,9 @@ class RenderViewImpl : public RenderWidget,
virtual void runModal();
virtual bool enterFullScreen();
virtual void exitFullScreen();
+ virtual bool requestPointerLock();
+ virtual void requestPointerUnlock();
+ virtual bool isPointerLocked();
// WebKit::WebViewClient implementation --------------------------------------
@@ -806,12 +814,10 @@ class RenderViewImpl : public RenderWidget,
const std::vector<GURL>& links,
const std::vector<FilePath>& local_paths,
const FilePath& local_directory_name);
- void OnLockMouseACK(bool succeeded);
void OnMediaPlayerActionAt(const gfx::Point& location,
const WebKit::WebMediaPlayerAction& action);
void OnPluginActionAt(const gfx::Point& location,
const WebKit::WebPluginAction& action);
- void OnMouseLockLost();
void OnMoveOrResizeStarted();
CONTENT_EXPORT void OnNavigate(const ViewMsg_Navigate_Params& params);
void OnPaste();
@@ -1164,6 +1170,9 @@ class RenderViewImpl : public RenderWidget,
// Java Bridge dispatcher attached to this view; lazily initialized.
scoped_ptr<JavaBridgeDispatcher> java_bridge_dispatcher_;
+ // Mouse Lock dispatcher attached to this view.
+ MouseLockDispatcher* mouse_lock_dispatcher_;
+
// Misc ----------------------------------------------------------------------
// The current and pending file chooser completion objects. If the queue is
@@ -1222,6 +1231,9 @@ class RenderViewImpl : public RenderWidget,
// of handling a ViewMsg_SelectRange IPC.
bool handling_select_range_;
+ // Wraps the |webwidget_| as a MouseLockDispatcher::LockTarget interface.
+ scoped_ptr<MouseLockDispatcher::LockTarget> webwidget_mouse_lock_target_;
+
// Plugins -------------------------------------------------------------------
// All the currently active plugin delegates for this RenderView; kept so

Powered by Google App Engine
This is Rietveld 408576698