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) 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. | 6 Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. |
7 | 7 |
8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 memoryCache()->revalidationFailed(resource); | 129 memoryCache()->revalidationFailed(resource); |
130 resource->error(CachedResource::LoadError); | 130 resource->error(CachedResource::LoadError); |
131 return PassOwnPtr<CachedResourceRequest>(nullptr); | 131 return PassOwnPtr<CachedResourceRequest>(nullptr); |
132 } | 132 } |
133 request->m_loader = loader; | 133 request->m_loader = loader; |
134 return request.release(); | 134 return request.release(); |
135 } | 135 } |
136 | 136 |
137 void CachedResourceRequest::willSendRequest(SubresourceLoader* loader, ResourceR
equest& req, const ResourceResponse&) | 137 void CachedResourceRequest::willSendRequest(SubresourceLoader* loader, ResourceR
equest& req, const ResourceResponse&) |
138 { | 138 { |
139 if (!m_cachedResourceLoader->checkInsecureContent(m_resource->type(), req.ur
l())) { | 139 if (!m_cachedResourceLoader->canRequest(m_resource->type(), req.url())) { |
140 loader->cancel(); | 140 loader->cancel(); |
141 return; | 141 return; |
142 } | 142 } |
143 m_resource->setRequestedFromNetworkingLayer(); | 143 m_resource->setRequestedFromNetworkingLayer(); |
144 } | 144 } |
145 | 145 |
146 void CachedResourceRequest::didFinishLoading(SubresourceLoader* loader, double) | 146 void CachedResourceRequest::didFinishLoading(SubresourceLoader* loader, double) |
147 { | 147 { |
148 if (m_finishing) | 148 if (m_finishing) |
149 return; | 149 return; |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
278 m_resource->setSerializedCachedMetadata(data, size); | 278 m_resource->setSerializedCachedMetadata(data, size); |
279 } | 279 } |
280 | 280 |
281 void CachedResourceRequest::end() | 281 void CachedResourceRequest::end() |
282 { | 282 { |
283 m_cachedResourceLoader->loadDone(); | 283 m_cachedResourceLoader->loadDone(); |
284 m_resource->stopLoading(); | 284 m_resource->stopLoading(); |
285 } | 285 } |
286 | 286 |
287 } //namespace WebCore | 287 } //namespace WebCore |
OLD | NEW |