OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "chrome/browser/renderer_host/render_view_host.h" | 5 #include "chrome/browser/renderer_host/render_view_host.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 1171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1182 const std::string& security_origin) { | 1182 const std::string& security_origin) { |
1183 RenderViewHostDelegate::Resource* resource_delegate = | 1183 RenderViewHostDelegate::Resource* resource_delegate = |
1184 delegate_->GetResourceDelegate(); | 1184 delegate_->GetResourceDelegate(); |
1185 if (resource_delegate) | 1185 if (resource_delegate) |
1186 resource_delegate->DidRunInsecureContent(security_origin); | 1186 resource_delegate->DidRunInsecureContent(security_origin); |
1187 } | 1187 } |
1188 | 1188 |
1189 void RenderViewHost::OnMsgDidStartProvisionalLoadForFrame(long long frame_id, | 1189 void RenderViewHost::OnMsgDidStartProvisionalLoadForFrame(long long frame_id, |
1190 bool is_main_frame, | 1190 bool is_main_frame, |
1191 const GURL& url) { | 1191 const GURL& url) { |
| 1192 bool unreachable_web_data = (url.spec() == chrome::kUnreachableWebDataURL); |
1192 GURL validated_url(url); | 1193 GURL validated_url(url); |
1193 FilterURL(ChildProcessSecurityPolicy::GetInstance(), | 1194 FilterURL(ChildProcessSecurityPolicy::GetInstance(), |
1194 process()->id(), &validated_url); | 1195 process()->id(), &validated_url); |
1195 | 1196 |
1196 RenderViewHostDelegate::Resource* resource_delegate = | 1197 RenderViewHostDelegate::Resource* resource_delegate = |
1197 delegate_->GetResourceDelegate(); | 1198 delegate_->GetResourceDelegate(); |
1198 if (resource_delegate) { | 1199 if (resource_delegate) { |
1199 resource_delegate->DidStartProvisionalLoadForFrame( | 1200 resource_delegate->DidStartProvisionalLoadForFrame( |
1200 this, frame_id, is_main_frame, validated_url); | 1201 this, frame_id, is_main_frame, unreachable_web_data, validated_url); |
1201 } | 1202 } |
1202 } | 1203 } |
1203 | 1204 |
1204 void RenderViewHost::OnMsgDidFailProvisionalLoadWithError( | 1205 void RenderViewHost::OnMsgDidFailProvisionalLoadWithError( |
1205 long long frame_id, | 1206 long long frame_id, |
1206 bool is_main_frame, | 1207 bool is_main_frame, |
1207 int error_code, | 1208 int error_code, |
1208 const GURL& url, | 1209 const GURL& url, |
1209 bool showing_repost_interstitial) { | 1210 bool showing_repost_interstitial) { |
1210 VLOG(1) << "Failed Provisional Load: " << url.possibly_invalid_spec() | 1211 VLOG(1) << "Failed Provisional Load: " << url.possibly_invalid_spec() |
(...skipping 1033 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2244 TabContents* print_preview_tab = GetOrCreatePrintPreviewTab(); | 2245 TabContents* print_preview_tab = GetOrCreatePrintPreviewTab(); |
2245 DCHECK(print_preview_tab); | 2246 DCHECK(print_preview_tab); |
2246 | 2247 |
2247 // TODO(kmadhusu): Function definition needs to be changed. | 2248 // TODO(kmadhusu): Function definition needs to be changed. |
2248 // fd_in_browser should be the file descriptor of the metafile. | 2249 // fd_in_browser should be the file descriptor of the metafile. |
2249 | 2250 |
2250 // Send the printingDone msg for now. | 2251 // Send the printingDone msg for now. |
2251 Send(new ViewMsg_PrintingDone(routing_id(), -1, true)); | 2252 Send(new ViewMsg_PrintingDone(routing_id(), -1, true)); |
2252 } | 2253 } |
2253 #endif | 2254 #endif |
OLD | NEW |