| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 | 74 |
| 75 bool isYoungest() const { return !youngerShadowRoot(); } | 75 bool isYoungest() const { return !youngerShadowRoot(); } |
| 76 bool isOldest() const { return !olderShadowRoot(); } | 76 bool isOldest() const { return !olderShadowRoot(); } |
| 77 bool isOldestAuthorShadowRoot() const; | 77 bool isOldestAuthorShadowRoot() const; |
| 78 | 78 |
| 79 virtual void attach(const AttachContext& = AttachContext()) OVERRIDE; | 79 virtual void attach(const AttachContext& = AttachContext()) OVERRIDE; |
| 80 | 80 |
| 81 virtual InsertionNotificationRequest insertedInto(ContainerNode*) OVERRIDE; | 81 virtual InsertionNotificationRequest insertedInto(ContainerNode*) OVERRIDE; |
| 82 virtual void removedFrom(ContainerNode*) OVERRIDE; | 82 virtual void removedFrom(ContainerNode*) OVERRIDE; |
| 83 | 83 |
| 84 virtual void registerScopedHTMLStyleChild() OVERRIDE; | 84 void registerScopedHTMLStyleChild(); |
| 85 virtual void unregisterScopedHTMLStyleChild() OVERRIDE; | 85 void unregisterScopedHTMLStyleChild(); |
| 86 | 86 |
| 87 bool containsShadowElements() const; | 87 bool containsShadowElements() const; |
| 88 bool containsContentElements() const; | 88 bool containsContentElements() const; |
| 89 bool containsInsertionPoints() const { return containsShadowElements() || co
ntainsContentElements(); } | 89 bool containsInsertionPoints() const { return containsShadowElements() || co
ntainsContentElements(); } |
| 90 bool containsShadowRoots() const; | 90 bool containsShadowRoots() const; |
| 91 | 91 |
| 92 unsigned descendantShadowElementCount() const; | 92 unsigned descendantShadowElementCount() const; |
| 93 | 93 |
| 94 // For Internals, don't use this. | 94 // For Internals, don't use this. |
| 95 unsigned childShadowRootCount() const; | 95 unsigned childShadowRootCount() const; |
| 96 unsigned numberOfStyles() const { return m_numberOfStyles; } |
| 96 | 97 |
| 97 HTMLShadowElement* shadowInsertionPointOfYoungerShadowRoot() const; | 98 HTMLShadowElement* shadowInsertionPointOfYoungerShadowRoot() const; |
| 98 void setShadowInsertionPointOfYoungerShadowRoot(PassRefPtr<HTMLShadowElement
>); | 99 void setShadowInsertionPointOfYoungerShadowRoot(PassRefPtr<HTMLShadowElement
>); |
| 99 | 100 |
| 100 void didAddInsertionPoint(InsertionPoint*); | 101 void didAddInsertionPoint(InsertionPoint*); |
| 101 void didRemoveInsertionPoint(InsertionPoint*); | 102 void didRemoveInsertionPoint(InsertionPoint*); |
| 102 const Vector<RefPtr<InsertionPoint> >& descendantInsertionPoints(); | 103 const Vector<RefPtr<InsertionPoint> >& descendantInsertionPoints(); |
| 103 | 104 |
| 104 ShadowRootType type() const { return static_cast<ShadowRootType>(m_type); } | 105 ShadowRootType type() const { return static_cast<ShadowRootType>(m_type); } |
| 105 | 106 |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 { | 157 { |
| 157 return adjustedFocusedElement(); | 158 return adjustedFocusedElement(); |
| 158 } | 159 } |
| 159 | 160 |
| 160 DEFINE_NODE_TYPE_CASTS(ShadowRoot, isShadowRoot()); | 161 DEFINE_NODE_TYPE_CASTS(ShadowRoot, isShadowRoot()); |
| 161 DEFINE_TYPE_CASTS(ShadowRoot, TreeScope, treeScope, treeScope->rootNode().isShad
owRoot(), treeScope.rootNode().isShadowRoot()); | 162 DEFINE_TYPE_CASTS(ShadowRoot, TreeScope, treeScope, treeScope->rootNode().isShad
owRoot(), treeScope.rootNode().isShadowRoot()); |
| 162 | 163 |
| 163 } // namespace | 164 } // namespace |
| 164 | 165 |
| 165 #endif | 166 #endif |
| OLD | NEW |