| 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 265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 276 DCHECK(GetProcess()->HasConnection()); | 276 DCHECK(GetProcess()->HasConnection()); |
| 277 DCHECK(GetProcess()->GetBrowserContext()); | 277 DCHECK(GetProcess()->GetBrowserContext()); |
| 278 CHECK(main_frame_routing_id_ != MSG_ROUTING_NONE || | 278 CHECK(main_frame_routing_id_ != MSG_ROUTING_NONE || |
| 279 proxy_route_id != MSG_ROUTING_NONE); | 279 proxy_route_id != MSG_ROUTING_NONE); |
| 280 | 280 |
| 281 // We should not set both main_frame_routing_id_ and proxy_route_id. Log | 281 // We should not set both main_frame_routing_id_ and proxy_route_id. Log |
| 282 // cases that this happens (without crashing) to track down | 282 // cases that this happens (without crashing) to track down |
| 283 // https://crbug.com/575245. | 283 // https://crbug.com/575245. |
| 284 // TODO(creis): Remove this once we've found the cause. | 284 // TODO(creis): Remove this once we've found the cause. |
| 285 if (main_frame_routing_id_ != MSG_ROUTING_NONE && | 285 if (main_frame_routing_id_ != MSG_ROUTING_NONE && |
| 286 proxy_route_id != MSG_ROUTING_NONE) | 286 proxy_route_id != MSG_ROUTING_NONE) { |
| 287 NOTREACHED() << "Don't set both main_frame_routing_id_ and proxy_route_id"; |
| 287 base::debug::DumpWithoutCrashing(); | 288 base::debug::DumpWithoutCrashing(); |
| 289 } |
| 288 | 290 |
| 289 GetWidget()->set_renderer_initialized(true); | 291 GetWidget()->set_renderer_initialized(true); |
| 290 | 292 |
| 291 mojom::CreateViewParamsPtr params = mojom::CreateViewParams::New(); | 293 mojom::CreateViewParamsPtr params = mojom::CreateViewParams::New(); |
| 292 params->renderer_preferences = | 294 params->renderer_preferences = |
| 293 delegate_->GetRendererPrefs(GetProcess()->GetBrowserContext()); | 295 delegate_->GetRendererPrefs(GetProcess()->GetBrowserContext()); |
| 294 GetPlatformSpecificPrefs(¶ms->renderer_preferences); | 296 GetPlatformSpecificPrefs(¶ms->renderer_preferences); |
| 295 params->web_preferences = GetWebkitPreferences(); | 297 params->web_preferences = GetWebkitPreferences(); |
| 296 params->view_id = GetRoutingID(); | 298 params->view_id = GetRoutingID(); |
| 297 params->main_frame_routing_id = main_frame_routing_id_; | 299 params->main_frame_routing_id = main_frame_routing_id_; |
| (...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 958 } | 960 } |
| 959 | 961 |
| 960 void RenderViewHostImpl::ClosePageTimeout() { | 962 void RenderViewHostImpl::ClosePageTimeout() { |
| 961 if (delegate_->ShouldIgnoreUnresponsiveRenderer()) | 963 if (delegate_->ShouldIgnoreUnresponsiveRenderer()) |
| 962 return; | 964 return; |
| 963 | 965 |
| 964 ClosePageIgnoringUnloadEvents(); | 966 ClosePageIgnoringUnloadEvents(); |
| 965 } | 967 } |
| 966 | 968 |
| 967 } // namespace content | 969 } // namespace content |
| OLD | NEW |