Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(274)

Side by Side Diff: Source/core/fetch/ImageResource.h

Issue 1291883002: Use precaching for more data: urls than just images. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Tweak determineRevalidationPolicy ordering Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/fetch/FetchContext.h ('k') | Source/core/fetch/ImageResource.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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) 2006 Samuel Weinig (sam.weinig@gmail.com) 4 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com)
5 Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. 5 Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved.
6 6
7 This library is free software; you can redistribute it and/or 7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public 8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either 9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version. 10 version 2 of the License, or (at your option) any later version.
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 114
115 bool shouldPauseAnimation(const blink::Image*) override; 115 bool shouldPauseAnimation(const blink::Image*) override;
116 void animationAdvanced(const blink::Image*) override; 116 void animationAdvanced(const blink::Image*) override;
117 void changedInRect(const blink::Image*, const IntRect&) override; 117 void changedInRect(const blink::Image*, const IntRect&) override;
118 118
119 protected: 119 protected:
120 bool isSafeToUnlock() const override; 120 bool isSafeToUnlock() const override;
121 void destroyDecodedDataIfPossible() override; 121 void destroyDecodedDataIfPossible() override;
122 122
123 private: 123 private:
124 static void preCacheDataURIImage(const FetchRequest&, ResourceFetcher*);
125
126 class ImageResourceFactory : public ResourceFactory { 124 class ImageResourceFactory : public ResourceFactory {
127 public: 125 public:
128 ImageResourceFactory() 126 ImageResourceFactory()
129 : ResourceFactory(Resource::Image) { } 127 : ResourceFactory(Resource::Image) { }
130 128
131 Resource* create(const ResourceRequest& request, const String&) const ov erride 129 Resource* create(const ResourceRequest& request, const String&) const ov erride
132 { 130 {
133 return new ImageResource(request); 131 return new ImageResource(request);
134 } 132 }
135 }; 133 };
(...skipping 18 matching lines...) Expand all
154 152
155 RefPtr<blink::Image> m_image; 153 RefPtr<blink::Image> m_image;
156 bool m_hasDevicePixelRatioHeaderValue; 154 bool m_hasDevicePixelRatioHeaderValue;
157 }; 155 };
158 156
159 DEFINE_RESOURCE_TYPE_CASTS(Image); 157 DEFINE_RESOURCE_TYPE_CASTS(Image);
160 158
161 } 159 }
162 160
163 #endif 161 #endif
OLDNEW
« no previous file with comments | « Source/core/fetch/FetchContext.h ('k') | Source/core/fetch/ImageResource.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698