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 276 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
287 | 287 |
288 // The process may (if we're sharing a process with another host that already | 288 // The process may (if we're sharing a process with another host that already |
289 // initialized it) or may not (we have our own process or the old process | 289 // initialized it) or may not (we have our own process or the old process |
290 // crashed) have been initialized. Calling Init multiple times will be | 290 // crashed) have been initialized. Calling Init multiple times will be |
291 // ignored, so this is safe. | 291 // ignored, so this is safe. |
292 if (!GetProcess()->Init()) | 292 if (!GetProcess()->Init()) |
293 return false; | 293 return false; |
294 DCHECK(GetProcess()->HasConnection()); | 294 DCHECK(GetProcess()->HasConnection()); |
295 DCHECK(GetProcess()->GetBrowserContext()); | 295 DCHECK(GetProcess()->GetBrowserContext()); |
296 | 296 |
| 297 CHECK(main_frame_routing_id_ != MSG_ROUTING_NONE || |
| 298 proxy_route_id != MSG_ROUTING_NONE); |
| 299 |
297 set_renderer_initialized(true); | 300 set_renderer_initialized(true); |
298 | 301 |
299 // Ensure the RenderView starts with a next_page_id larger than any existing | 302 // Ensure the RenderView starts with a next_page_id larger than any existing |
300 // page ID it might be asked to render. | 303 // page ID it might be asked to render. |
301 int32 next_page_id = 1; | 304 int32 next_page_id = 1; |
302 if (max_page_id > -1) | 305 if (max_page_id > -1) |
303 next_page_id = max_page_id + 1; | 306 next_page_id = max_page_id + 1; |
304 | 307 |
305 ViewMsg_New_Params params; | 308 ViewMsg_New_Params params; |
306 params.renderer_preferences = | 309 params.renderer_preferences = |
(...skipping 1151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1458 } else { | 1461 } else { |
1459 render_view_ready_on_process_launch_ = true; | 1462 render_view_ready_on_process_launch_ = true; |
1460 } | 1463 } |
1461 } | 1464 } |
1462 | 1465 |
1463 void RenderViewHostImpl::RenderViewReady() { | 1466 void RenderViewHostImpl::RenderViewReady() { |
1464 delegate_->RenderViewReady(this); | 1467 delegate_->RenderViewReady(this); |
1465 } | 1468 } |
1466 | 1469 |
1467 } // namespace content | 1470 } // namespace content |
OLD | NEW |