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

Side by Side Diff: Source/core/rendering/shapes/ShapeOutsideInfo.cpp

Issue 815933006: Change all uses of the RoundedRect class to use FloatRoundedRect instead. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 12 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/rendering/shapes/Shape.cpp ('k') | Source/core/rendering/style/RenderStyle.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. 2 * Copyright (C) 2012 Adobe Systems Incorporated. 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 * 7 *
8 * 1. Redistributions of source code must retain the above 8 * 1. Redistributions of source code must retain the above
9 * copyright notice, this list of conditions and the following 9 * copyright notice, this list of conditions and the following
10 * disclaimer. 10 * disclaimer.
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 switch (shapeValue.type()) { 159 switch (shapeValue.type()) {
160 case ShapeValue::Shape: 160 case ShapeValue::Shape:
161 ASSERT(shapeValue.shape()); 161 ASSERT(shapeValue.shape());
162 m_shape = Shape::createShape(shapeValue.shape(), m_referenceBoxLogicalSi ze, writingMode, margin); 162 m_shape = Shape::createShape(shapeValue.shape(), m_referenceBoxLogicalSi ze, writingMode, margin);
163 break; 163 break;
164 case ShapeValue::Image: 164 case ShapeValue::Image:
165 ASSERT(shapeValue.isImageValid()); 165 ASSERT(shapeValue.isImageValid());
166 m_shape = createShapeForImage(shapeValue.image(), shapeImageThreshold, w ritingMode, margin); 166 m_shape = createShapeForImage(shapeValue.image(), shapeImageThreshold, w ritingMode, margin);
167 break; 167 break;
168 case ShapeValue::Box: { 168 case ShapeValue::Box: {
169 const RoundedRect& shapeRect = style.getRoundedBorderFor(LayoutRect(Layo utPoint(), m_referenceBoxLogicalSize), m_renderer.view()); 169 const FloatRoundedRect& shapeRect = style.getRoundedBorderFor(LayoutRect (LayoutPoint(), m_referenceBoxLogicalSize), m_renderer.view());
170 m_shape = Shape::createLayoutBoxShape(shapeRect, writingMode, margin); 170 m_shape = Shape::createLayoutBoxShape(shapeRect, writingMode, margin);
171 break; 171 break;
172 } 172 }
173 } 173 }
174 174
175 ASSERT(m_shape); 175 ASSERT(m_shape);
176 return *m_shape; 176 return *m_shape;
177 } 177 }
178 178
179 inline LayoutUnit borderBeforeInWritingMode(const RenderBox& renderer, WritingMo de writingMode) 179 inline LayoutUnit borderBeforeInWritingMode(const RenderBox& renderer, WritingMo de writingMode)
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
341 } 341 }
342 342
343 FloatSize ShapeOutsideInfo::shapeToRendererSize(FloatSize size) const 343 FloatSize ShapeOutsideInfo::shapeToRendererSize(FloatSize size) const
344 { 344 {
345 if (!m_renderer.style()->isHorizontalWritingMode()) 345 if (!m_renderer.style()->isHorizontalWritingMode())
346 return size.transposedSize(); 346 return size.transposedSize();
347 return size; 347 return size;
348 } 348 }
349 349
350 } // namespace blink 350 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/rendering/shapes/Shape.cpp ('k') | Source/core/rendering/style/RenderStyle.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698