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

Unified Diff: third_party/WebKit/Source/core/style/StylePendingImage.h

Issue 2941533002: Break StyleImage dependency on LayoutObject (Closed)
Patch Set: Address reviewer comments Created 3 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/style/StylePendingImage.h
diff --git a/third_party/WebKit/Source/core/style/StylePendingImage.h b/third_party/WebKit/Source/core/style/StylePendingImage.h
index 69f96e1e5ac39d17430500d777d21fb642556b4e..129cb35c56312ed9e518450c664fcc0bb5bf674f 100644
--- a/third_party/WebKit/Source/core/style/StylePendingImage.h
+++ b/third_party/WebKit/Source/core/style/StylePendingImage.h
@@ -35,6 +35,8 @@
namespace blink {
+class ImageResourceObserver;
+
// StylePendingImage is a placeholder StyleImage that is entered into the
// ComputedStyle during style resolution, in order to avoid loading images that
// are not referenced by the final style. They should never exist in a
@@ -77,9 +79,11 @@ class StylePendingImage final : public StyleImage {
}
bool ImageHasRelativeSize() const override { return false; }
bool UsesImageContainerSize() const override { return false; }
- void AddClient(LayoutObject*) override {}
- void RemoveClient(LayoutObject*) override {}
- PassRefPtr<Image> GetImage(const LayoutObject&,
+ void AddClient(ImageResourceObserver*) override {}
+ void RemoveClient(ImageResourceObserver*) override {}
+ PassRefPtr<Image> GetImage(const ImageResourceObserver&,
+ const Document&,
+ const ComputedStyle&,
const IntSize&) const override {
NOTREACHED();
return nullptr;

Powered by Google App Engine
This is Rietveld 408576698