OLD | NEW |
1 /* | 1 /* |
2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) | 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) |
3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) | 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) |
4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) | 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) |
5 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All | 5 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All |
6 rights reserved. | 6 rights reserved. |
7 Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/ | 7 Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/ |
8 | 8 |
9 This library is free software; you can redistribute it and/or | 9 This library is free software; you can redistribute it and/or |
10 modify it under the terms of the GNU Library General Public | 10 modify it under the terms of the GNU Library General Public |
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 ResourceFetcher::ResourceFetcher(FetchContext* newContext) | 246 ResourceFetcher::ResourceFetcher(FetchContext* newContext) |
247 : m_context(newContext), | 247 : m_context(newContext), |
248 m_archive(context().isMainFrame() ? nullptr : context().archive()), | 248 m_archive(context().isMainFrame() ? nullptr : context().archive()), |
249 m_resourceTimingReportTimer( | 249 m_resourceTimingReportTimer( |
250 this, | 250 this, |
251 &ResourceFetcher::resourceTimingReportTimerFired), | 251 &ResourceFetcher::resourceTimingReportTimerFired), |
252 m_autoLoadImages(true), | 252 m_autoLoadImages(true), |
253 m_imagesEnabled(true), | 253 m_imagesEnabled(true), |
254 m_allowStaleResources(false), | 254 m_allowStaleResources(false), |
255 m_imageFetched(false) { | 255 m_imageFetched(false) { |
256 ThreadState::current()->registerPreFinalizer(this); | |
257 } | 256 } |
258 | 257 |
259 ResourceFetcher::~ResourceFetcher() {} | 258 ResourceFetcher::~ResourceFetcher() {} |
260 | 259 |
261 Resource* ResourceFetcher::cachedResource(const KURL& resourceURL) const { | 260 Resource* ResourceFetcher::cachedResource(const KURL& resourceURL) const { |
262 KURL url = MemoryCache::removeFragmentIdentifierIfNeeded(resourceURL); | 261 KURL url = MemoryCache::removeFragmentIdentifierIfNeeded(resourceURL); |
263 const WeakMember<Resource>& resource = m_documentResources.get(url); | 262 const WeakMember<Resource>& resource = m_documentResources.get(url); |
264 return resource.get(); | 263 return resource.get(); |
265 } | 264 } |
266 | 265 |
(...skipping 1255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1522 visitor->trace(m_context); | 1521 visitor->trace(m_context); |
1523 visitor->trace(m_archive); | 1522 visitor->trace(m_archive); |
1524 visitor->trace(m_loaders); | 1523 visitor->trace(m_loaders); |
1525 visitor->trace(m_nonBlockingLoaders); | 1524 visitor->trace(m_nonBlockingLoaders); |
1526 visitor->trace(m_documentResources); | 1525 visitor->trace(m_documentResources); |
1527 visitor->trace(m_preloads); | 1526 visitor->trace(m_preloads); |
1528 visitor->trace(m_resourceTimingInfoMap); | 1527 visitor->trace(m_resourceTimingInfoMap); |
1529 } | 1528 } |
1530 | 1529 |
1531 } // namespace blink | 1530 } // namespace blink |
OLD | NEW |