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 Apple Inc. All rights reserved. | 6 Copyright (C) 2004, 2005, 2006, 2007 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 | 129 |
130 class ImageResource::ImageResourceFactory : public ResourceFactory { | 130 class ImageResource::ImageResourceFactory : public ResourceFactory { |
131 STACK_ALLOCATED(); | 131 STACK_ALLOCATED(); |
132 | 132 |
133 public: | 133 public: |
134 ImageResourceFactory(const FetchRequest& fetchRequest) | 134 ImageResourceFactory(const FetchRequest& fetchRequest) |
135 : ResourceFactory(Resource::Image), m_fetchRequest(&fetchRequest) {} | 135 : ResourceFactory(Resource::Image), m_fetchRequest(&fetchRequest) {} |
136 | 136 |
137 Resource* create(const ResourceRequest& request, | 137 Resource* create(const ResourceRequest& request, |
138 const ResourceLoaderOptions& options, | 138 const ResourceLoaderOptions& options, |
139 const String&) const override { | 139 const String&, |
| 140 FetchContext*) const override { |
140 return new ImageResource(request, options, ImageResourceContent::create(), | 141 return new ImageResource(request, options, ImageResourceContent::create(), |
141 m_fetchRequest->placeholderImageRequestType() == | 142 m_fetchRequest->placeholderImageRequestType() == |
142 FetchRequest::AllowPlaceholder); | 143 FetchRequest::AllowPlaceholder); |
143 } | 144 } |
144 | 145 |
145 private: | 146 private: |
146 // Weak, unowned pointer. Must outlive |this|. | 147 // Weak, unowned pointer. Must outlive |this|. |
147 const FetchRequest* m_fetchRequest; | 148 const FetchRequest* m_fetchRequest; |
148 }; | 149 }; |
149 | 150 |
(...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
591 // reloading in Step 3 due to notifyObservers()'s | 592 // reloading in Step 3 due to notifyObservers()'s |
592 // schedulingReloadOrShouldReloadBrokenPlaceholder() check. | 593 // schedulingReloadOrShouldReloadBrokenPlaceholder() check. |
593 // 3. reloadIfLoFiOrPlaceholderImage() is called via ResourceFetcher | 594 // 3. reloadIfLoFiOrPlaceholderImage() is called via ResourceFetcher |
594 // (a) via didFinishLoading() called in decodeError(), or | 595 // (a) via didFinishLoading() called in decodeError(), or |
595 // (b) after returning ImageResource::updateImage(). | 596 // (b) after returning ImageResource::updateImage(). |
596 decodeError(allDataReceived); | 597 decodeError(allDataReceived); |
597 } | 598 } |
598 } | 599 } |
599 | 600 |
600 } // namespace blink | 601 } // namespace blink |
OLD | NEW |