| OLD | NEW |
| 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 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 m_image = image; | 78 m_image = image; |
| 79 } | 79 } |
| 80 CSSBoxType cssBox() const { return m_cssBox; } | 80 CSSBoxType cssBox() const { return m_cssBox; } |
| 81 | 81 |
| 82 bool operator==(const ShapeValue& other) const; | 82 bool operator==(const ShapeValue& other) const; |
| 83 | 83 |
| 84 DEFINE_INLINE_VIRTUAL_TRACE() { visitor->trace(m_image); } | 84 DEFINE_INLINE_VIRTUAL_TRACE() { visitor->trace(m_image); } |
| 85 | 85 |
| 86 private: | 86 private: |
| 87 ShapeValue(PassRefPtr<BasicShape> shape, CSSBoxType cssBox) | 87 ShapeValue(PassRefPtr<BasicShape> shape, CSSBoxType cssBox) |
| 88 : m_type(Shape), m_shape(shape), m_cssBox(cssBox) {} | 88 : m_type(Shape), m_shape(std::move(shape)), m_cssBox(cssBox) {} |
| 89 ShapeValue(ShapeValueType type) : m_type(type), m_cssBox(BoxMissing) {} | 89 ShapeValue(ShapeValueType type) : m_type(type), m_cssBox(BoxMissing) {} |
| 90 ShapeValue(StyleImage* image) | 90 ShapeValue(StyleImage* image) |
| 91 : m_type(Image), m_image(image), m_cssBox(ContentBox) {} | 91 : m_type(Image), m_image(image), m_cssBox(ContentBox) {} |
| 92 ShapeValue(CSSBoxType cssBox) : m_type(Box), m_cssBox(cssBox) {} | 92 ShapeValue(CSSBoxType cssBox) : m_type(Box), m_cssBox(cssBox) {} |
| 93 | 93 |
| 94 ShapeValueType m_type; | 94 ShapeValueType m_type; |
| 95 RefPtr<BasicShape> m_shape; | 95 RefPtr<BasicShape> m_shape; |
| 96 Member<StyleImage> m_image; | 96 Member<StyleImage> m_image; |
| 97 CSSBoxType m_cssBox; | 97 CSSBoxType m_cssBox; |
| 98 }; | 98 }; |
| (...skipping 12 matching lines...) Expand all Loading... |
| 111 return dataEquivalent(image(), other.image()); | 111 return dataEquivalent(image(), other.image()); |
| 112 } | 112 } |
| 113 | 113 |
| 114 NOTREACHED(); | 114 NOTREACHED(); |
| 115 return false; | 115 return false; |
| 116 } | 116 } |
| 117 | 117 |
| 118 } // namespace blink | 118 } // namespace blink |
| 119 | 119 |
| 120 #endif | 120 #endif |
| OLD | NEW |