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

Unified Diff: android_webview/native/aw_contents_client_bridge.cc

Issue 1180223004: Check user gesture before firing an intent in WebView (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed failing test, added another Created 5 years, 5 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: android_webview/native/aw_contents_client_bridge.cc
diff --git a/android_webview/native/aw_contents_client_bridge.cc b/android_webview/native/aw_contents_client_bridge.cc
index 671e9739182deecf77590146767bc881393c0dac..2b16fcc89614becab919eee98bdd14be40b1814d 100644
--- a/android_webview/native/aw_contents_client_bridge.cc
+++ b/android_webview/native/aw_contents_client_bridge.cc
@@ -341,7 +341,7 @@ void AwContentsClientBridge::RunBeforeUnloadDialog(
}
bool AwContentsClientBridge::ShouldOverrideUrlLoading(
- const base::string16& url) {
+ const base::string16& url, bool has_user_gesture, bool is_redirect) {
JNIEnv* env = AttachCurrentThread();
ScopedJavaLocalRef<jobject> obj = java_ref_.get(env);
if (obj.is_null())
@@ -351,7 +351,7 @@ bool AwContentsClientBridge::ShouldOverrideUrlLoading(
"shouldOverrideUrlLoading");
return Java_AwContentsClientBridge_shouldOverrideUrlLoading(
env, obj.obj(),
- jurl.obj());
+ jurl.obj(), has_user_gesture, is_redirect);
}
void AwContentsClientBridge::ConfirmJsResult(JNIEnv* env,

Powered by Google App Engine
This is Rietveld 408576698