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

Side by Side Diff: android_webview/native/aw_contents_statics.cc

Issue 281563002: [Android WebView] Filter out error page URL from onPageFinished to un-flake tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Restore import of Runnable Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « android_webview/javatests/src/org/chromium/android_webview/test/ClientOnPageStartedTest.java ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "android_webview/native/aw_contents_statics.h" 5 #include "android_webview/native/aw_contents_statics.h"
6 6
7 #include "android_webview/browser/aw_browser_context.h" 7 #include "android_webview/browser/aw_browser_context.h"
8 #include "base/android/jni_string.h" 8 #include "base/android/jni_string.h"
9 #include "base/android/scoped_java_ref.h" 9 #include "base/android/scoped_java_ref.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
11 #include "components/data_reduction_proxy/browser/data_reduction_proxy_settings. h" 11 #include "components/data_reduction_proxy/browser/data_reduction_proxy_settings. h"
12 #include "content/public/browser/browser_thread.h" 12 #include "content/public/browser/browser_thread.h"
13 #include "content/public/common/url_constants.h"
13 #include "jni/AwContentsStatics_jni.h" 14 #include "jni/AwContentsStatics_jni.h"
14 #include "net/cert/cert_database.h" 15 #include "net/cert/cert_database.h"
15 16
16 using base::android::AttachCurrentThread; 17 using base::android::AttachCurrentThread;
17 using base::android::ConvertJavaStringToUTF8; 18 using base::android::ConvertJavaStringToUTF8;
18 using base::android::ScopedJavaGlobalRef; 19 using base::android::ScopedJavaGlobalRef;
19 using content::BrowserThread; 20 using content::BrowserThread;
20 using data_reduction_proxy::DataReductionProxySettings; 21 using data_reduction_proxy::DataReductionProxySettings;
21 22
22 namespace android_webview { 23 namespace android_webview {
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 browser_context->GetDataReductionProxySettings(); 57 browser_context->GetDataReductionProxySettings();
57 if (drp_settings) 58 if (drp_settings)
58 drp_settings->params()->set_key(ConvertJavaStringToUTF8(env, key)); 59 drp_settings->params()->set_key(ConvertJavaStringToUTF8(env, key));
59 } 60 }
60 61
61 // static 62 // static
62 void SetDataReductionProxyEnabled(JNIEnv* env, jclass, jboolean enabled) { 63 void SetDataReductionProxyEnabled(JNIEnv* env, jclass, jboolean enabled) {
63 AwBrowserContext::SetDataReductionProxyEnabled(enabled); 64 AwBrowserContext::SetDataReductionProxyEnabled(enabled);
64 } 65 }
65 66
67 // static
68 jstring GetUnreachableWebDataUrl(JNIEnv* env, jclass) {
69 return base::android::ConvertUTF8ToJavaString(
70 env, content::kUnreachableWebDataURL).Release();
71 }
72
66 bool RegisterAwContentsStatics(JNIEnv* env) { 73 bool RegisterAwContentsStatics(JNIEnv* env) {
67 return RegisterNativesImpl(env); 74 return RegisterNativesImpl(env);
68 } 75 }
69 76
70 } // namespace android_webview 77 } // namespace android_webview
OLDNEW
« no previous file with comments | « android_webview/javatests/src/org/chromium/android_webview/test/ClientOnPageStartedTest.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698