| 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 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 unsigned m_numberOfStyles : 27; | 138 unsigned m_numberOfStyles : 27; |
| 139 unsigned m_applyAuthorStyles : 1; | 139 unsigned m_applyAuthorStyles : 1; |
| 140 unsigned m_resetStyleInheritance : 1; | 140 unsigned m_resetStyleInheritance : 1; |
| 141 unsigned m_type : 1; | 141 unsigned m_type : 1; |
| 142 unsigned m_registeredWithParentShadowRoot : 1; | 142 unsigned m_registeredWithParentShadowRoot : 1; |
| 143 unsigned m_childInsertionPointsIsValid : 1; | 143 unsigned m_childInsertionPointsIsValid : 1; |
| 144 }; | 144 }; |
| 145 | 145 |
| 146 inline Element* ShadowRoot::activeElement() const | 146 inline Element* ShadowRoot::activeElement() const |
| 147 { | 147 { |
| 148 if (Element* element = treeScope().adjustedFocusedElement()) | 148 if (Element* element = treeScope()->adjustedFocusedElement()) |
| 149 return element; | 149 return element; |
| 150 return 0; | 150 return 0; |
| 151 } | 151 } |
| 152 | 152 |
| 153 inline const ShadowRoot* toShadowRoot(const Node* node) | 153 inline const ShadowRoot* toShadowRoot(const Node* node) |
| 154 { | 154 { |
| 155 ASSERT_WITH_SECURITY_IMPLICATION(!node || node->isShadowRoot()); | 155 ASSERT_WITH_SECURITY_IMPLICATION(!node || node->isShadowRoot()); |
| 156 return static_cast<const ShadowRoot*>(node); | 156 return static_cast<const ShadowRoot*>(node); |
| 157 } | 157 } |
| 158 | 158 |
| (...skipping 21 matching lines...) Expand all Loading... |
| 180 | 180 |
| 181 inline ShadowRoot& toShadowRoot(TreeScope& treeScope) | 181 inline ShadowRoot& toShadowRoot(TreeScope& treeScope) |
| 182 { | 182 { |
| 183 ASSERT_WITH_SECURITY_IMPLICATION(treeScope.rootNode() && treeScope.rootNode(
)->isShadowRoot()); | 183 ASSERT_WITH_SECURITY_IMPLICATION(treeScope.rootNode() && treeScope.rootNode(
)->isShadowRoot()); |
| 184 return static_cast<ShadowRoot&>(treeScope); | 184 return static_cast<ShadowRoot&>(treeScope); |
| 185 } | 185 } |
| 186 | 186 |
| 187 } // namespace | 187 } // namespace |
| 188 | 188 |
| 189 #endif | 189 #endif |
| OLD | NEW |