OLD | NEW |
---|---|
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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.h" | 5 #include "android_webview/native/aw_contents.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "android_webview/browser/aw_browser_context.h" | 9 #include "android_webview/browser/aw_browser_context.h" |
10 #include "android_webview/browser/aw_browser_main_parts.h" | 10 #include "android_webview/browser/aw_browser_main_parts.h" |
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
238 contents_client_bridge_.get()); | 238 contents_client_bridge_.get()); |
239 | 239 |
240 AwContentsIoThreadClientImpl::Associate( | 240 AwContentsIoThreadClientImpl::Associate( |
241 web_contents_.get(), ScopedJavaLocalRef<jobject>(env, io_thread_client)); | 241 web_contents_.get(), ScopedJavaLocalRef<jobject>(env, io_thread_client)); |
242 | 242 |
243 InterceptNavigationDelegate::Associate( | 243 InterceptNavigationDelegate::Associate( |
244 web_contents_.get(), | 244 web_contents_.get(), |
245 make_scoped_ptr(new InterceptNavigationDelegate( | 245 make_scoped_ptr(new InterceptNavigationDelegate( |
246 env, intercept_navigation_delegate))); | 246 env, intercept_navigation_delegate))); |
247 | 247 |
248 web_contents_->ResumeLoadingCreatedWebContents(); | |
249 | |
248 // Finally, having setup the associations, release any deferred requests | 250 // Finally, having setup the associations, release any deferred requests |
249 web_contents_->ForEachFrame(base::Bind(&OnIoThreadClientReady)); | 251 web_contents_->ForEachFrame(base::Bind(&OnIoThreadClientReady)); |
gsennton
2015/10/30 15:02:43
Not sure whether ResumeLoadingCreatedWebContents s
| |
250 } | 252 } |
251 | 253 |
252 void AwContents::SetSaveFormData(bool enabled) { | 254 void AwContents::SetSaveFormData(bool enabled) { |
253 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 255 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
254 InitAutofillIfNecessary(enabled); | 256 InitAutofillIfNecessary(enabled); |
255 // We need to check for the existence, since autofill_manager_delegate | 257 // We need to check for the existence, since autofill_manager_delegate |
256 // may not be created when the setting is false. | 258 // may not be created when the setting is false. |
257 if (AwAutofillClient::FromWebContents(web_contents_.get())) { | 259 if (AwAutofillClient::FromWebContents(web_contents_.get())) { |
258 AwAutofillClient::FromWebContents(web_contents_.get())-> | 260 AwAutofillClient::FromWebContents(web_contents_.get())-> |
259 SetSaveFormData(enabled); | 261 SetSaveFormData(enabled); |
(...skipping 962 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1222 content::ChildProcessSecurityPolicy::GetInstance()->GrantScheme( | 1224 content::ChildProcessSecurityPolicy::GetInstance()->GrantScheme( |
1223 web_contents_->GetRenderProcessHost()->GetID(), url::kFileScheme); | 1225 web_contents_->GetRenderProcessHost()->GetID(), url::kFileScheme); |
1224 } | 1226 } |
1225 | 1227 |
1226 void SetShouldDownloadFavicons(JNIEnv* env, | 1228 void SetShouldDownloadFavicons(JNIEnv* env, |
1227 const JavaParamRef<jclass>& jclazz) { | 1229 const JavaParamRef<jclass>& jclazz) { |
1228 g_should_download_favicons = true; | 1230 g_should_download_favicons = true; |
1229 } | 1231 } |
1230 | 1232 |
1231 } // namespace android_webview | 1233 } // namespace android_webview |
OLD | NEW |