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

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

Issue 1774943003: blink: Rename platform/ methods to prefix with get when they collide. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: clash-platform: rebase-yayyyyyyyy Created 4 years, 9 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
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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 // Exposed for testing 58 // Exposed for testing
59 static PassRefPtrWillBeRawPtr<ImageResource> create(const ResourceRequest& r equest, blink::Image* image) 59 static PassRefPtrWillBeRawPtr<ImageResource> create(const ResourceRequest& r equest, blink::Image* image)
60 { 60 {
61 return adoptRefWillBeNoop(new ImageResource(request, image)); 61 return adoptRefWillBeNoop(new ImageResource(request, image));
62 } 62 }
63 63
64 ~ImageResource() override; 64 ~ImageResource() override;
65 65
66 void load(ResourceFetcher*, const ResourceLoaderOptions&) override; 66 void load(ResourceFetcher*, const ResourceLoaderOptions&) override;
67 67
68 blink::Image* image(); // Returns the nullImage() if the image is not availa ble yet. 68 blink::Image* getImage(); // Returns the nullImage() if the image is not ava ilable yet.
69 bool hasImage() const { return m_image.get(); } 69 bool hasImage() const { return m_image.get(); }
70 70
71 static std::pair<blink::Image*, float> brokenImage(float deviceScaleFactor); // Returns an image and the image's resolution scale factor. 71 static std::pair<blink::Image*, float> brokenImage(float deviceScaleFactor); // Returns an image and the image's resolution scale factor.
72 bool willPaintBrokenImage() const; 72 bool willPaintBrokenImage() const;
73 73
74 bool usesImageContainerSize() const; 74 bool usesImageContainerSize() const;
75 bool imageHasRelativeSize() const; 75 bool imageHasRelativeSize() const;
76 // The device pixel ratio we got from the server for this image, or 1.0. 76 // The device pixel ratio we got from the server for this image, or 1.0.
77 float devicePixelRatioHeaderValue() const { return m_devicePixelRatioHeaderV alue; } 77 float devicePixelRatioHeaderValue() const { return m_devicePixelRatioHeaderV alue; }
78 bool hasDevicePixelRatioHeaderValue() const { return m_hasDevicePixelRatioHe aderValue; } 78 bool hasDevicePixelRatioHeaderValue() const { return m_hasDevicePixelRatioHe aderValue; }
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 153
154 RefPtr<blink::Image> m_image; 154 RefPtr<blink::Image> m_image;
155 bool m_hasDevicePixelRatioHeaderValue; 155 bool m_hasDevicePixelRatioHeaderValue;
156 }; 156 };
157 157
158 DEFINE_RESOURCE_TYPE_CASTS(Image); 158 DEFINE_RESOURCE_TYPE_CASTS(Image);
159 159
160 } // namespace blink 160 } // namespace blink
161 161
162 #endif 162 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698