| Index: extensions/renderer/messaging_bindings.cc
|
| diff --git a/extensions/renderer/messaging_bindings.cc b/extensions/renderer/messaging_bindings.cc
|
| index 281f27641fab51c568e06f357161d5aba163d9f7..d442681479ebe64a7fd4970795caa7ef1fe2d70e 100644
|
| --- a/extensions/renderer/messaging_bindings.cc
|
| +++ b/extensions/renderer/messaging_bindings.cc
|
| @@ -29,7 +29,6 @@
|
| #include "third_party/WebKit/public/web/WebScopedUserGesture.h"
|
| #include "third_party/WebKit/public/web/WebScopedWindowFocusAllowedIndicator.h"
|
| #include "third_party/WebKit/public/web/WebUserGestureIndicator.h"
|
| -#include "third_party/WebKit/public/web/WebUserGestureToken.h"
|
| #include "v8/include/v8.h"
|
|
|
| // Message passing API example (in a content script):
|
| @@ -105,12 +104,6 @@ class ExtensionImpl : public ObjectBackedNativeHandler {
|
| dispatcher_->ClearPortData(port_id);
|
| }
|
|
|
| - bool ShouldForwardUserGesture() {
|
| - return blink::WebUserGestureIndicator::isProcessingUserGesture() &&
|
| - !blink::WebUserGestureIndicator::currentUserGestureToken()
|
| - .wasForwarded();
|
| - }
|
| -
|
| // Sends a message along the given channel.
|
| void PostMessage(const v8::FunctionCallbackInfo<v8::Value>& args) {
|
| content::RenderView* renderview = context()->GetRenderView();
|
| @@ -128,9 +121,9 @@ class ExtensionImpl : public ObjectBackedNativeHandler {
|
| }
|
|
|
| renderview->Send(new ExtensionHostMsg_PostMessage(
|
| - renderview->GetRoutingID(),
|
| - port_id,
|
| - Message(*v8::String::Utf8Value(args[1]), ShouldForwardUserGesture())));
|
| + renderview->GetRoutingID(), port_id,
|
| + Message(*v8::String::Utf8Value(args[1]),
|
| + blink::WebUserGestureIndicator::isProcessingUserGesture())));
|
| }
|
|
|
| // Forcefully disconnects a port.
|
| @@ -361,7 +354,6 @@ void MessagingBindings::DeliverMessage(
|
| scoped_ptr<blink::WebScopedWindowFocusAllowedIndicator> allow_window_focus;
|
| if (message.user_gesture) {
|
| web_user_gesture.reset(new blink::WebScopedUserGesture);
|
| - blink::WebUserGestureIndicator::currentUserGestureToken().setForwarded();
|
| allow_window_focus.reset(new blink::WebScopedWindowFocusAllowedIndicator);
|
| }
|
|
|
|
|