OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. 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 are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Neither the name of Google Inc. nor the names of its | 10 * * Neither the name of Google Inc. nor the names of its |
(...skipping 27 matching lines...) Expand all Loading... |
38 namespace blink { | 38 namespace blink { |
39 | 39 |
40 class CORE_EXPORT ElementShadow final : public GarbageCollectedFinalized<Element
Shadow> { | 40 class CORE_EXPORT ElementShadow final : public GarbageCollectedFinalized<Element
Shadow> { |
41 WTF_MAKE_NONCOPYABLE(ElementShadow); | 41 WTF_MAKE_NONCOPYABLE(ElementShadow); |
42 public: | 42 public: |
43 static ElementShadow* create(); | 43 static ElementShadow* create(); |
44 ~ElementShadow(); | 44 ~ElementShadow(); |
45 | 45 |
46 Element& host() const; | 46 Element& host() const; |
47 ShadowRoot& youngestShadowRoot() const; | 47 ShadowRoot& youngestShadowRoot() const; |
48 ShadowRoot* oldestShadowRoot() const { return m_shadowRoot; } | 48 ShadowRoot& oldestShadowRoot() const { DCHECK(m_shadowRoot); return *m_shado
wRoot; } |
49 ElementShadow* containingShadow() const; | 49 ElementShadow* containingShadow() const; |
50 | 50 |
51 ShadowRoot& addShadowRoot(Element& shadowHost, ShadowRootType); | 51 ShadowRoot& addShadowRoot(Element& shadowHost, ShadowRootType); |
52 | 52 |
53 bool hasSameStyles(const ElementShadow*) const; | 53 bool hasSameStyles(const ElementShadow*) const; |
54 | 54 |
55 void attach(const Node::AttachContext&); | 55 void attach(const Node::AttachContext&); |
56 void detach(const Node::AttachContext&); | 56 void detach(const Node::AttachContext&); |
57 | 57 |
58 void willAffectSelector(); | 58 void willAffectSelector(); |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 inline void ElementShadow::distributeIfNeeded() | 129 inline void ElementShadow::distributeIfNeeded() |
130 { | 130 { |
131 if (m_needsDistributionRecalc) | 131 if (m_needsDistributionRecalc) |
132 distribute(); | 132 distribute(); |
133 m_needsDistributionRecalc = false; | 133 m_needsDistributionRecalc = false; |
134 } | 134 } |
135 | 135 |
136 } // namespace blink | 136 } // namespace blink |
137 | 137 |
138 #endif | 138 #endif |
OLD | NEW |