OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/frame_host/frame_tree.h" | 5 #include "content/browser/frame_host/frame_tree.h" |
6 | 6 |
7 #include <queue> | 7 #include <queue> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
226 // Create the swapped out RVH for the new SiteInstance. This will create | 226 // Create the swapped out RVH for the new SiteInstance. This will create |
227 // a top-level swapped out RFH as well, which will then be wrapped by a | 227 // a top-level swapped out RFH as well, which will then be wrapped by a |
228 // RenderFrameProxyHost. | 228 // RenderFrameProxyHost. |
229 if (!source || !source->IsMainFrame()) { | 229 if (!source || !source->IsMainFrame()) { |
230 RenderViewHostImpl* render_view_host = GetRenderViewHost(site_instance); | 230 RenderViewHostImpl* render_view_host = GetRenderViewHost(site_instance); |
231 if (!render_view_host) { | 231 if (!render_view_host) { |
232 if (SiteIsolationPolicy::IsSwappedOutStateForbidden()) { | 232 if (SiteIsolationPolicy::IsSwappedOutStateForbidden()) { |
233 root()->render_manager()->CreateRenderFrameProxy(site_instance); | 233 root()->render_manager()->CreateRenderFrameProxy(site_instance); |
234 } else { | 234 } else { |
235 root()->render_manager()->CreateRenderFrame( | 235 root()->render_manager()->CreateRenderFrame( |
236 site_instance, nullptr, CREATE_RF_SWAPPED_OUT | CREATE_RF_HIDDEN, | 236 site_instance, CREATE_RF_SWAPPED_OUT | CREATE_RF_HIDDEN, nullptr); |
237 nullptr); | |
238 } | 237 } |
239 } else { | 238 } else { |
240 root()->render_manager()->EnsureRenderViewInitialized(render_view_host, | 239 root()->render_manager()->EnsureRenderViewInitialized(render_view_host, |
241 site_instance); | 240 site_instance); |
242 } | 241 } |
243 } | 242 } |
244 | 243 |
245 scoped_refptr<SiteInstance> instance(site_instance); | 244 scoped_refptr<SiteInstance> instance(site_instance); |
246 | 245 |
247 // Proxies are created in the FrameTree in response to a node navigating to a | 246 // Proxies are created in the FrameTree in response to a node navigating to a |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
405 load_progress_ = 0.0; | 404 load_progress_ = 0.0; |
406 } | 405 } |
407 | 406 |
408 bool FrameTree::IsLoading() { | 407 bool FrameTree::IsLoading() { |
409 bool is_loading = false; | 408 bool is_loading = false; |
410 ForEach(base::Bind(&IsNodeLoading, &is_loading)); | 409 ForEach(base::Bind(&IsNodeLoading, &is_loading)); |
411 return is_loading; | 410 return is_loading; |
412 } | 411 } |
413 | 412 |
414 } // namespace content | 413 } // namespace content |
OLD | NEW |