| 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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading | 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading |
| 6 | 6 |
| 7 #include "content/browser/loader/resource_dispatcher_host_impl.h" | 7 #include "content/browser/loader/resource_dispatcher_host_impl.h" |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 464 | 464 |
| 465 ANNOTATE_BENIGN_RACE( | 465 ANNOTATE_BENIGN_RACE( |
| 466 &last_user_gesture_time_, | 466 &last_user_gesture_time_, |
| 467 "We don't care about the precise value, see http://crbug.com/92889"); | 467 "We don't care about the precise value, see http://crbug.com/92889"); |
| 468 | 468 |
| 469 BrowserThread::PostTask(BrowserThread::IO, | 469 BrowserThread::PostTask(BrowserThread::IO, |
| 470 FROM_HERE, | 470 FROM_HERE, |
| 471 base::Bind(&ResourceDispatcherHostImpl::OnInit, | 471 base::Bind(&ResourceDispatcherHostImpl::OnInit, |
| 472 base::Unretained(this))); | 472 base::Unretained(this))); |
| 473 | 473 |
| 474 update_load_states_timer_.reset( | 474 update_load_states_timer_.reset(new base::RepeatingTimer()); |
| 475 new base::RepeatingTimer<ResourceDispatcherHostImpl>()); | |
| 476 } | 475 } |
| 477 | 476 |
| 478 ResourceDispatcherHostImpl::~ResourceDispatcherHostImpl() { | 477 ResourceDispatcherHostImpl::~ResourceDispatcherHostImpl() { |
| 479 DCHECK(outstanding_requests_stats_map_.empty()); | 478 DCHECK(outstanding_requests_stats_map_.empty()); |
| 480 DCHECK(g_resource_dispatcher_host); | 479 DCHECK(g_resource_dispatcher_host); |
| 481 g_resource_dispatcher_host = NULL; | 480 g_resource_dispatcher_host = NULL; |
| 482 } | 481 } |
| 483 | 482 |
| 484 // static | 483 // static |
| 485 ResourceDispatcherHostImpl* ResourceDispatcherHostImpl::Get() { | 484 ResourceDispatcherHostImpl* ResourceDispatcherHostImpl::Get() { |
| (...skipping 1913 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2399 load_flags |= net::LOAD_PREFETCH; | 2398 load_flags |= net::LOAD_PREFETCH; |
| 2400 } | 2399 } |
| 2401 | 2400 |
| 2402 if (is_sync_load) | 2401 if (is_sync_load) |
| 2403 load_flags |= net::LOAD_IGNORE_LIMITS; | 2402 load_flags |= net::LOAD_IGNORE_LIMITS; |
| 2404 | 2403 |
| 2405 return load_flags; | 2404 return load_flags; |
| 2406 } | 2405 } |
| 2407 | 2406 |
| 2408 } // namespace content | 2407 } // namespace content |
| OLD | NEW |