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

Unified Diff: webkit/plugins/ppapi/ppapi_plugin_instance.h

Issue 9558009: Add HandleInputEventAck message to allow out-of-process plugins to respond to user gestures. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 9 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
« no previous file with comments | « ppapi/thunk/ppb_instance_api.h ('k') | webkit/plugins/ppapi/ppapi_plugin_instance.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppapi_plugin_instance.h
===================================================================
--- webkit/plugins/ppapi/ppapi_plugin_instance.h (revision 125463)
+++ webkit/plugins/ppapi/ppapi_plugin_instance.h (working copy)
@@ -23,6 +23,7 @@
#include "ppapi/c/pp_completion_callback.h"
#include "ppapi/c/pp_instance.h"
#include "ppapi/c/pp_resource.h"
+#include "ppapi/c/pp_time.h"
#include "ppapi/c/pp_var.h"
#include "ppapi/c/ppb_audio_config.h"
#include "ppapi/c/ppb_input_event.h"
@@ -272,13 +273,13 @@
// Because going to/from fullscreen is asynchronous, there are 4 states:
// - normal : desired_fullscreen_state_ == false
- // fullscreen_ == false
+ // view_data_.is_fullscreen == false
// - fullscreen pending: desired_fullscreen_state_ == true
- // fullscreen_ == false
+ // view_data_.is_fullscreen == false
// - fullscreen : desired_fullscreen_state_ == true
- // fullscreen_ == true
+ // view_data_.is_fullscreen == true
// - normal pending : desired_fullscreen_state_ = false
- // fullscreen_ = true
+ // view_data_.is_fullscreen = true
bool IsFullscreenOrPending();
// Switches between fullscreen and normal mode. The transition is
@@ -358,6 +359,8 @@
uint32_t event_classes) OVERRIDE;
virtual void ClearInputEventRequest(PP_Instance instance,
uint32_t event_classes) OVERRIDE;
+ virtual void ClosePendingUserGesture(PP_Instance instance,
+ PP_TimeTicks timestamp);
virtual void ZoomChanged(PP_Instance instance, double factor) OVERRIDE;
virtual void ZoomLimitsChanged(PP_Instance instance,
double minimum_factor,
@@ -473,6 +476,9 @@
void SetSizeAttributesForFullscreen();
void ResetSizeAttributesAfterFullscreen();
+ // Helper function to determine if an action has a user gesture.
+ bool HasUserGesture();
+
PluginDelegate* delegate_;
scoped_refptr<PluginModule> module_;
scoped_ptr< ::ppapi::PPP_Instance_Combined> instance_interface_;
@@ -620,6 +626,10 @@
PP_CompletionCallback lock_mouse_callback_;
+ // Track pending user gestures so out-of-process plugins can respond to
+ // a user gesture after it has been processed.
+ PP_TimeTicks pending_user_gesture_;
+
DISALLOW_COPY_AND_ASSIGN(PluginInstance);
};
« no previous file with comments | « ppapi/thunk/ppb_instance_api.h ('k') | webkit/plugins/ppapi/ppapi_plugin_instance.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698