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

Unified Diff: third_party/WebKit/Source/web/WebLocalFrameImpl.cpp

Issue 2408333004: Move persistent gesture state to Document, add DocumentUserGestureToken (Closed)
Patch Set: Re-add dropped null check Created 4 years, 2 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: third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp b/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
index c0dffe073239c9626bb6734bdbde53eb45c11eaa..0b5db4345b09c172ed0ced603228f3cc9fae5721 100644
--- a/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
+++ b/third_party/WebKit/Source/web/WebLocalFrameImpl.cpp
@@ -100,6 +100,7 @@
#include "bindings/core/v8/V8PerIsolateData.h"
#include "core/HTMLNames.h"
#include "core/dom/Document.h"
+#include "core/dom/DocumentUserGestureToken.h"
#include "core/dom/IconURL.h"
#include "core/dom/MessagePort.h"
#include "core/dom/Node.h"
@@ -1900,8 +1901,8 @@ void WebLocalFrameImpl::loadJavaScriptURL(const KURL& url) {
String script = decodeURLEscapeSequences(
url.getString().substring(strlen("javascript:")));
- UserGestureIndicator gestureIndicator(
- UserGestureToken::create(UserGestureToken::NewGesture));
+ UserGestureIndicator gestureIndicator(DocumentUserGestureToken::create(
+ frame()->document(), UserGestureToken::NewGesture));
v8::HandleScope handleScope(toIsolate(frame()));
v8::Local<v8::Value> result =
frame()->script().executeScriptInMainWorldAndReturnValue(
« no previous file with comments | « third_party/WebKit/Source/web/WebFrameWidgetImpl.cpp ('k') | third_party/WebKit/Source/web/WebPluginContainerImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698