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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 return node.isInsertionPoint() && toInsertionPoint(node).isShadowInsertionPo
int(); | 97 return node.isInsertionPoint() && toInsertionPoint(node).isShadowInsertionPo
int(); |
98 } | 98 } |
99 | 99 |
100 // TODO(hayato): The function name is confusing. This neither resolve a reprojec
tion nor support v1 shadow trees. | 100 // TODO(hayato): The function name is confusing. This neither resolve a reprojec
tion nor support v1 shadow trees. |
101 inline ElementShadow* shadowWhereNodeCanBeDistributed(const Node& node) | 101 inline ElementShadow* shadowWhereNodeCanBeDistributed(const Node& node) |
102 { | 102 { |
103 Node* parent = node.parentNode(); | 103 Node* parent = node.parentNode(); |
104 if (!parent) | 104 if (!parent) |
105 return 0; | 105 return 0; |
106 if (parent->isShadowRoot() && !toShadowRoot(parent)->isYoungest()) | 106 if (parent->isShadowRoot() && !toShadowRoot(parent)->isYoungest()) |
107 return node.shadowHost()->shadow(); | 107 return node.ownerShadowHost()->shadow(); |
108 if (isActiveInsertionPoint(*parent)) | 108 if (isActiveInsertionPoint(*parent)) |
109 return node.shadowHost()->shadow(); | 109 return node.ownerShadowHost()->shadow(); |
110 if (parent->isElementNode()) | 110 if (parent->isElementNode()) |
111 return toElement(parent)->shadow(); | 111 return toElement(parent)->shadow(); |
112 return 0; | 112 return 0; |
113 } | 113 } |
114 | 114 |
115 const InsertionPoint* resolveReprojection(const Node*); | 115 const InsertionPoint* resolveReprojection(const Node*); |
116 | 116 |
117 void collectDestinationInsertionPoints(const Node&, HeapVector<Member<InsertionP
oint>, 8>& results); | 117 void collectDestinationInsertionPoints(const Node&, HeapVector<Member<InsertionP
oint>, 8>& results); |
118 | 118 |
119 } // namespace blink | 119 } // namespace blink |
120 | 120 |
121 #endif // InsertionPoint_h | 121 #endif // InsertionPoint_h |
OLD | NEW |