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

Side by Side Diff: Source/core/rendering/style/BasicShapes.h

Issue 144143005: Preserve shape-box order in non-computed values (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Updating patch to trunk Created 6 years, 9 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/css/parser/CSSPropertyParser.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 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 bool canBlend(const BasicShape*) const; 62 bool canBlend(const BasicShape*) const;
63 bool isSameType(const BasicShape& other) const { return type() == other.type (); } 63 bool isSameType(const BasicShape& other) const { return type() == other.type (); }
64 64
65 virtual void path(Path&, const FloatRect&) = 0; 65 virtual void path(Path&, const FloatRect&) = 0;
66 virtual WindRule windRule() const { return RULE_NONZERO; } 66 virtual WindRule windRule() const { return RULE_NONZERO; }
67 virtual PassRefPtr<BasicShape> blend(const BasicShape*, double) const = 0; 67 virtual PassRefPtr<BasicShape> blend(const BasicShape*, double) const = 0;
68 virtual bool operator==(const BasicShape&) const = 0; 68 virtual bool operator==(const BasicShape&) const = 0;
69 69
70 virtual Type type() const = 0; 70 virtual Type type() const = 0;
71 71
72 LayoutBox layoutBox() const { return m_layoutBox; }
73 void setLayoutBox(LayoutBox layoutBox) { m_layoutBox = layoutBox; }
74
75 protected: 72 protected:
76 BasicShape() 73 BasicShape()
77 : m_layoutBox(BoxMissing)
78 { 74 {
79 } 75 }
80 76
81 private:
82 LayoutBox m_layoutBox;
83 }; 77 };
84 78
85 #define DEFINE_BASICSHAPE_TYPE_CASTS(thisType) \ 79 #define DEFINE_BASICSHAPE_TYPE_CASTS(thisType) \
86 DEFINE_TYPE_CASTS(thisType, BasicShape, value, value->type() == BasicShape:: thisType##Type, value.type() == BasicShape::thisType##Type) 80 DEFINE_TYPE_CASTS(thisType, BasicShape, value, value->type() == BasicShape:: thisType##Type, value.type() == BasicShape::thisType##Type)
87 81
88 class BasicShapeRectangle FINAL : public BasicShape { 82 class BasicShapeRectangle FINAL : public BasicShape {
89 public: 83 public:
90 static PassRefPtr<BasicShapeRectangle> create() { return adoptRef(new BasicS hapeRectangle); } 84 static PassRefPtr<BasicShapeRectangle> create() { return adoptRef(new BasicS hapeRectangle); }
91 85
92 Length x() const { return m_x; } 86 Length x() const { return m_x; }
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
436 LengthSize m_topLeftRadius; 430 LengthSize m_topLeftRadius;
437 LengthSize m_topRightRadius; 431 LengthSize m_topRightRadius;
438 LengthSize m_bottomRightRadius; 432 LengthSize m_bottomRightRadius;
439 LengthSize m_bottomLeftRadius; 433 LengthSize m_bottomLeftRadius;
440 }; 434 };
441 435
442 DEFINE_BASICSHAPE_TYPE_CASTS(BasicShapeInset); 436 DEFINE_BASICSHAPE_TYPE_CASTS(BasicShapeInset);
443 437
444 } 438 }
445 #endif 439 #endif
OLDNEW
« no previous file with comments | « Source/core/css/parser/CSSPropertyParser.cpp ('k') | Source/core/rendering/style/ShapeValue.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698