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

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

Issue 226323002: [CSS Shapes] Remove outside-shape CSS value (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 8 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
« no previous file with comments | « Source/core/rendering/shapes/ShapeInfo.cpp ('k') | Source/core/rendering/style/ShapeValue.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 30 matching lines...) Expand all
41 if (!box.isFloating() || !shapeValue) 41 if (!box.isFloating() || !shapeValue)
42 return false; 42 return false;
43 43
44 switch (shapeValue->type()) { 44 switch (shapeValue->type()) {
45 case ShapeValue::Shape: 45 case ShapeValue::Shape:
46 return shapeValue->shape(); 46 return shapeValue->shape();
47 case ShapeValue::Image: 47 case ShapeValue::Image:
48 return shapeValue->isImageValid() && checkShapeImageOrigin(box.document( ), *(shapeValue->image()->cachedImage())); 48 return shapeValue->isImageValid() && checkShapeImageOrigin(box.document( ), *(shapeValue->image()->cachedImage()));
49 case ShapeValue::Box: 49 case ShapeValue::Box:
50 return true; 50 return true;
51 case ShapeValue::Outside:
52 return false;
53 } 51 }
54 52
55 return false; 53 return false;
56 } 54 }
57 55
58 void ShapeOutsideInfo::updateDeltasForContainingBlockLine(const RenderBlockFlow& containingBlock, const FloatingObject& floatingObject, LayoutUnit lineTop, Layo utUnit lineHeight) 56 void ShapeOutsideInfo::updateDeltasForContainingBlockLine(const RenderBlockFlow& containingBlock, const FloatingObject& floatingObject, LayoutUnit lineTop, Layo utUnit lineHeight)
59 { 57 {
60 LayoutUnit borderBoxTop = containingBlock.logicalTopForFloat(&floatingObject ) + containingBlock.marginBeforeForChild(&m_renderer); 58 LayoutUnit borderBoxTop = containingBlock.logicalTopForFloat(&floatingObject ) + containingBlock.marginBeforeForChild(&m_renderer);
61 LayoutUnit borderBoxLineTop = lineTop - borderBoxTop; 59 LayoutUnit borderBoxLineTop = lineTop - borderBoxTop;
62 60
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 return m_renderer.style()->shapeOutside(); 94 return m_renderer.style()->shapeOutside();
97 } 95 }
98 96
99 const RenderStyle* ShapeOutsideInfo::styleForWritingMode() const 97 const RenderStyle* ShapeOutsideInfo::styleForWritingMode() const
100 { 98 {
101 ASSERT(m_renderer.containingBlock()); 99 ASSERT(m_renderer.containingBlock());
102 return m_renderer.containingBlock()->style(); 100 return m_renderer.containingBlock()->style();
103 } 101 }
104 102
105 } 103 }
OLDNEW
« no previous file with comments | « Source/core/rendering/shapes/ShapeInfo.cpp ('k') | Source/core/rendering/style/ShapeValue.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698