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

Unified Diff: third_party/WebKit/Source/core/style/StyleFetchedImage.cpp

Issue 2486073004: [ImageResource 1a] Change StyleFetchedImage from ResourceClient to ImageResourceObserver (Closed)
Patch Set: Rebase Created 4 years, 1 month 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
« no previous file with comments | « third_party/WebKit/Source/core/style/StyleFetchedImage.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/style/StyleFetchedImage.cpp
diff --git a/third_party/WebKit/Source/core/style/StyleFetchedImage.cpp b/third_party/WebKit/Source/core/style/StyleFetchedImage.cpp
index e2f1b4c1dc6c7df35bf4c31828b540f3ac80b09c..cb70d27aaeda09ba4115213ea773aa23ae91985b 100644
--- a/third_party/WebKit/Source/core/style/StyleFetchedImage.cpp
+++ b/third_party/WebKit/Source/core/style/StyleFetchedImage.cpp
@@ -36,7 +36,7 @@ StyleFetchedImage::StyleFetchedImage(ImageResource* image,
const KURL& url)
: m_image(image), m_document(&document), m_url(url) {
m_isImageResource = true;
- m_image->addClient(this);
+ m_image->addObserver(this);
// ResourceFetcher is not determined from StyleFetchedImage and it is
// impossible to send a request for refetching.
m_image->setNotRefetchableDataFromDiskCache();
@@ -46,7 +46,7 @@ StyleFetchedImage::StyleFetchedImage(ImageResource* image,
StyleFetchedImage::~StyleFetchedImage() {}
void StyleFetchedImage::dispose() {
- m_image->removeClient(this);
+ m_image->removeObserver(this);
m_image = nullptr;
}
@@ -110,7 +110,7 @@ void StyleFetchedImage::removeClient(LayoutObject* layoutObject) {
m_image->removeObserver(layoutObject);
}
-void StyleFetchedImage::notifyFinished(Resource* resource) {
+void StyleFetchedImage::imageNotifyFinished(ImageResource*) {
if (m_document && m_image && m_image->getImage() &&
m_image->getImage()->isSVGImage())
toSVGImage(m_image->getImage())->updateUseCounters(*m_document);
@@ -141,7 +141,6 @@ DEFINE_TRACE(StyleFetchedImage) {
visitor->trace(m_image);
visitor->trace(m_document);
StyleImage::trace(visitor);
- ResourceClient::trace(visitor);
}
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/style/StyleFetchedImage.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698