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

Unified Diff: Source/core/rendering/RenderBlock.cpp

Issue 404343002: Introduce DEFINE_CONTENT_DATA_TYPE_CASTS, and use it (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 5 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
« no previous file with comments | « Source/core/css/resolver/StyleResourceLoader.cpp ('k') | Source/core/rendering/RenderObject.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/RenderBlock.cpp
diff --git a/Source/core/rendering/RenderBlock.cpp b/Source/core/rendering/RenderBlock.cpp
index 9c91ba9dbd7ac85bec2bf97c2704ce2edb638ffc..7a4595189220fd889b048f09a08b345a08f23f86 100644
--- a/Source/core/rendering/RenderBlock.cpp
+++ b/Source/core/rendering/RenderBlock.cpp
@@ -204,10 +204,8 @@ static void appendImagesFromStyle(Vector<ImageResource*>& images, RenderStyle& b
appendLayers(images, blockStyle.maskLayers());
const ContentData* contentData = blockStyle.contentData();
- if (contentData && contentData->isImage()) {
- const ImageContentData* imageContentData = static_cast<const ImageContentData*>(contentData);
- appendImageIfNotNull(images, imageContentData->image());
- }
+ if (contentData && contentData->isImage())
+ appendImageIfNotNull(images, toImageContentData(contentData)->image());
if (blockStyle.boxReflect())
appendImageIfNotNull(images, blockStyle.boxReflect()->mask().image());
appendImageIfNotNull(images, blockStyle.listStyleImage());
« no previous file with comments | « Source/core/css/resolver/StyleResourceLoader.cpp ('k') | Source/core/rendering/RenderObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698