OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "content/browser/renderer_host/render_view_host_impl.h" | 5 #include "content/browser/renderer_host/render_view_host_impl.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
265 updating_web_preferences_(false), | 265 updating_web_preferences_(false), |
266 render_view_ready_on_process_launch_(false), | 266 render_view_ready_on_process_launch_(false), |
267 weak_factory_(this) { | 267 weak_factory_(this) { |
268 DCHECK(instance_.get()); | 268 DCHECK(instance_.get()); |
269 CHECK(delegate_); // http://crbug.com/82827 | 269 CHECK(delegate_); // http://crbug.com/82827 |
270 | 270 |
271 GetWidget()->set_owner_delegate(this); | 271 GetWidget()->set_owner_delegate(this); |
272 | 272 |
273 GetProcess()->AddObserver(this); | 273 GetProcess()->AddObserver(this); |
274 | 274 |
| 275 // New views may be created during RenderProcessHost::ProcessDied(), within a |
| 276 // brief window where the internal ChannelProxy is null. This ensures that the |
| 277 // ChannelProxy is re-initialized in such cases so that subsequent messages |
| 278 // make their way to the new renderer once its restarted. |
| 279 GetProcess()->EnableSendQueue(); |
| 280 |
275 if (ResourceDispatcherHostImpl::Get()) { | 281 if (ResourceDispatcherHostImpl::Get()) { |
276 BrowserThread::PostTask( | 282 BrowserThread::PostTask( |
277 BrowserThread::IO, FROM_HERE, | 283 BrowserThread::IO, FROM_HERE, |
278 base::Bind(&ResourceDispatcherHostImpl::OnRenderViewHostCreated, | 284 base::Bind(&ResourceDispatcherHostImpl::OnRenderViewHostCreated, |
279 base::Unretained(ResourceDispatcherHostImpl::Get()), | 285 base::Unretained(ResourceDispatcherHostImpl::Get()), |
280 GetProcess()->GetID(), GetRoutingID())); | 286 GetProcess()->GetID(), GetRoutingID())); |
281 } | 287 } |
282 } | 288 } |
283 | 289 |
284 RenderViewHostImpl::~RenderViewHostImpl() { | 290 RenderViewHostImpl::~RenderViewHostImpl() { |
(...skipping 1033 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1318 // Note: We are using the origin URL provided by the sender here. It may be | 1324 // Note: We are using the origin URL provided by the sender here. It may be |
1319 // different from the receiver's. | 1325 // different from the receiver's. |
1320 file_system_file.url = | 1326 file_system_file.url = |
1321 GURL(storage::GetIsolatedFileSystemRootURIString( | 1327 GURL(storage::GetIsolatedFileSystemRootURIString( |
1322 file_system_url.origin(), filesystem_id, std::string()) | 1328 file_system_url.origin(), filesystem_id, std::string()) |
1323 .append(register_name)); | 1329 .append(register_name)); |
1324 } | 1330 } |
1325 } | 1331 } |
1326 | 1332 |
1327 } // namespace content | 1333 } // namespace content |
OLD | NEW |