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

Side by Side Diff: third_party/WebKit/Source/core/style/StyleFetchedImageSet.cpp

Issue 1482953002: Drop dependency on LayoutObject in fetch/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Compile fix Created 5 years 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) 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 PassRefPtr<Image> StyleFetchedImageSet::image(const LayoutObject*, const IntSize & containerSize, float zoom) const 124 PassRefPtr<Image> StyleFetchedImageSet::image(const LayoutObject*, const IntSize & containerSize, float zoom) const
125 { 125 {
126 if (!m_bestFitImage->image()->isSVGImage()) 126 if (!m_bestFitImage->image()->isSVGImage())
127 return m_bestFitImage->image(); 127 return m_bestFitImage->image();
128 128
129 return SVGImageForContainer::create(toSVGImage(m_bestFitImage->image()), con tainerSize, zoom, m_url); 129 return SVGImageForContainer::create(toSVGImage(m_bestFitImage->image()), con tainerSize, zoom, m_url);
130 } 130 }
131 131
132 bool StyleFetchedImageSet::knownToBeOpaque(const LayoutObject* layoutObject) con st 132 bool StyleFetchedImageSet::knownToBeOpaque(const LayoutObject* layoutObject) con st
133 { 133 {
134 return m_bestFitImage->currentFrameKnownToBeOpaque(layoutObject); 134 TRACE_EVENT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "PaintImage", " data", InspectorPaintImageEvent::data(layoutObject, *m_bestFitImage.get()));
135 return m_bestFitImage->image()->currentFrameKnownToBeOpaque(Image::PreCacheM etadata);
135 } 136 }
136 137
137 DEFINE_TRACE(StyleFetchedImageSet) 138 DEFINE_TRACE(StyleFetchedImageSet)
138 { 139 {
139 visitor->trace(m_imageSetValue); 140 visitor->trace(m_imageSetValue);
140 StyleImage::trace(visitor); 141 StyleImage::trace(visitor);
141 } 142 }
142 143
143 } // namespace blink 144 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/style/StyleFetchedImage.cpp ('k') | third_party/WebKit/Source/core/svg/graphics/SVGImage.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698