| 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/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
| (...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 params->can_load_local_resources = entry.GetCanLoadLocalResources(); | 261 params->can_load_local_resources = entry.GetCanLoadLocalResources(); |
| 262 params->frame_to_navigate = entry.GetFrameToNavigate(); | 262 params->frame_to_navigate = entry.GetFrameToNavigate(); |
| 263 | 263 |
| 264 if (delegate) | 264 if (delegate) |
| 265 delegate->AddNavigationHeaders(params->url, ¶ms->extra_headers); | 265 delegate->AddNavigationHeaders(params->url, ¶ms->extra_headers); |
| 266 } | 266 } |
| 267 | 267 |
| 268 } // namespace | 268 } // namespace |
| 269 | 269 |
| 270 WebContents* WebContents::Create(const WebContents::CreateParams& params) { | 270 WebContents* WebContents::Create(const WebContents::CreateParams& params) { |
| 271 return WebContentsImpl::CreateWithOpener(params, NULL); | 271 return WebContentsImpl::CreateWithOpener( |
| 272 params, static_cast<WebContentsImpl*>(params.opener)); |
| 272 } | 273 } |
| 273 | 274 |
| 274 WebContents* WebContents::CreateWithSessionStorage( | 275 WebContents* WebContents::CreateWithSessionStorage( |
| 275 const WebContents::CreateParams& params, | 276 const WebContents::CreateParams& params, |
| 276 const SessionStorageNamespaceMap& session_storage_namespace_map) { | 277 const SessionStorageNamespaceMap& session_storage_namespace_map) { |
| 277 WebContentsImpl* new_contents = new WebContentsImpl( | 278 WebContentsImpl* new_contents = new WebContentsImpl( |
| 278 params.browser_context, NULL); | 279 params.browser_context, NULL); |
| 279 | 280 |
| 280 for (SessionStorageNamespaceMap::const_iterator it = | 281 for (SessionStorageNamespaceMap::const_iterator it = |
| 281 session_storage_namespace_map.begin(); | 282 session_storage_namespace_map.begin(); |
| (...skipping 3432 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3714 } | 3715 } |
| 3715 | 3716 |
| 3716 void WebContentsImpl::ClearAllPowerSaveBlockers() { | 3717 void WebContentsImpl::ClearAllPowerSaveBlockers() { |
| 3717 for (PowerSaveBlockerMap::iterator i(power_save_blockers_.begin()); | 3718 for (PowerSaveBlockerMap::iterator i(power_save_blockers_.begin()); |
| 3718 i != power_save_blockers_.end(); ++i) | 3719 i != power_save_blockers_.end(); ++i) |
| 3719 STLDeleteValues(&power_save_blockers_[i->first]); | 3720 STLDeleteValues(&power_save_blockers_[i->first]); |
| 3720 power_save_blockers_.clear(); | 3721 power_save_blockers_.clear(); |
| 3721 } | 3722 } |
| 3722 | 3723 |
| 3723 } // namespace content | 3724 } // namespace content |
| OLD | NEW |