Chromium Code Reviews| Index: webkit/plugins/ppapi/plugin_delegate.h |
| diff --git a/webkit/plugins/ppapi/plugin_delegate.h b/webkit/plugins/ppapi/plugin_delegate.h |
| index f63276e421e56fc9c31c188488b51e7d2058a296..6595fb80d83a90f4acced113f143b3c8304e4c21 100644 |
| --- a/webkit/plugins/ppapi/plugin_delegate.h |
| +++ b/webkit/plugins/ppapi/plugin_delegate.h |
| @@ -446,6 +446,19 @@ class PluginDelegate { |
| // Returns the current preferences. |
| virtual ::ppapi::Preferences GetPreferences() = 0; |
| + |
| + // Locks the mouse for |instance|. It will call |
| + // PluginInstance::OnLockMouseACK() to notify the instance when the operation |
| + // is completed. The call to OnLockMouseACK() may be synchronous (i.e., it may |
| + // be called when LockMouse() is still on the stack). |
| + virtual void LockMouse(PluginInstance* instance) = 0; |
| + // Unlocks the mouse if |instance| currently owns the mouse lock. Whenever an |
|
brettw
2011/09/14 22:17:58
I'd put a blank line above here.
yzshen1
2011/09/19 20:48:41
Done.
|
| + // plugin instance has lost the mouse lock, it will be notified by |
| + // PluginInstance::OnMouseLockLost(). Please note that UnlockMouse() is not |
| + // the only cause of losing mouse lock. For example, a user may press the Esc |
| + // key to quit the mouse lock mode, which also results in an OnMouseLockLost() |
| + // call to the current mouse lock owner. |
| + virtual void UnlockMouse(PluginInstance* instance) = 0; |
| }; |
| } // namespace ppapi |