OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright (C) 2012 Google Inc. All rights reserved. | 3 * Copyright (C) 2012 Google Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
11 * * Neither the name of Google Inc. nor the names of its | 11 * * Neither the name of Google Inc. nor the names of its |
12 * contributors may be used to endorse or promote products derived from | 12 * contributors may be used to endorse or promote products derived from |
13 * this software without specific prior written permission. | 13 * this software without specific prior written permission. |
14 * | 14 * |
15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | 15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
16 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | 16 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |
17 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | 17 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |
18 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | 18 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT |
19 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | 19 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | 20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
21 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 21 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 */ | 26 */ |
27 | 27 |
28 #include "config.h" | 28 #include "config.h" |
29 #include "ComposedShadowTreeWalker.h" | 29 #include "core/dom/ComposedShadowTreeWalker.h" |
30 | 30 |
31 #include "ContentDistributor.h" | 31 #include "ContentDistributor.h" |
32 #include "Element.h" | |
33 #include "ElementShadow.h" | |
34 #include "HTMLContentElement.h" | 32 #include "HTMLContentElement.h" |
35 #include "HTMLShadowElement.h" | 33 #include "HTMLShadowElement.h" |
36 #include "InsertionPoint.h" | 34 #include "InsertionPoint.h" |
37 #include "PseudoElement.h" | 35 #include "core/dom/Element.h" |
| 36 #include "core/dom/ElementShadow.h" |
| 37 #include "core/dom/PseudoElement.h" |
38 | 38 |
39 namespace WebCore { | 39 namespace WebCore { |
40 | 40 |
41 static inline ElementShadow* shadowFor(const Node* node) | 41 static inline ElementShadow* shadowFor(const Node* node) |
42 { | 42 { |
43 if (node && node->isElementNode()) | 43 if (node && node->isElementNode()) |
44 return toElement(node)->shadow(); | 44 return toElement(node)->shadow(); |
45 return 0; | 45 return 0; |
46 } | 46 } |
47 | 47 |
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
306 if (Node* n = traversePreviousSibling(m_node)) { | 306 if (Node* n = traversePreviousSibling(m_node)) { |
307 while (Node* child = traverseLastChild(n)) | 307 while (Node* child = traverseLastChild(n)) |
308 n = child; | 308 n = child; |
309 m_node = n; | 309 m_node = n; |
310 } else | 310 } else |
311 parent(); | 311 parent(); |
312 assertPostcondition(); | 312 assertPostcondition(); |
313 } | 313 } |
314 | 314 |
315 } // namespace | 315 } // namespace |
OLD | NEW |