| 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 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 148 setNeedsReattachLayoutTree(); | 148 setNeedsReattachLayoutTree(); |
| 149 } | 149 } |
| 150 | 150 |
| 151 // There's no style to update so just calling recalcStyle means we're updated. | 151 // There's no style to update so just calling recalcStyle means we're updated. |
| 152 clearNeedsStyleRecalc(); | 152 clearNeedsStyleRecalc(); |
| 153 | 153 |
| 154 recalcDescendantStyles(change); | 154 recalcDescendantStyles(change); |
| 155 clearChildNeedsStyleRecalc(); | 155 clearChildNeedsStyleRecalc(); |
| 156 } | 156 } |
| 157 | 157 |
| 158 void ShadowRoot::rebuildLayoutTree() { | 158 void ShadowRoot::rebuildLayoutTree(Text*& nextTextSibling) { |
| 159 // ShadowRoot doesn't support custom callbacks. | 159 // ShadowRoot doesn't support custom callbacks. |
| 160 DCHECK(!hasCustomStyleCallbacks()); | 160 DCHECK(!hasCustomStyleCallbacks()); |
| 161 | 161 |
| 162 StyleSharingDepthScope sharingScope(*this); | 162 StyleSharingDepthScope sharingScope(*this); |
| 163 | 163 |
| 164 clearNeedsReattachLayoutTree(); | 164 clearNeedsReattachLayoutTree(); |
| 165 rebuildChildrenLayoutTrees(); | 165 rebuildChildrenLayoutTrees(nextTextSibling); |
| 166 clearChildNeedsReattachLayoutTree(); | 166 clearChildNeedsReattachLayoutTree(); |
| 167 } | 167 } |
| 168 | 168 |
| 169 void ShadowRoot::attachLayoutTree(const AttachContext& context) { | 169 void ShadowRoot::attachLayoutTree(const AttachContext& context) { |
| 170 StyleSharingDepthScope sharingScope(*this); | 170 StyleSharingDepthScope sharingScope(*this); |
| 171 DocumentFragment::attachLayoutTree(context); | 171 DocumentFragment::attachLayoutTree(context); |
| 172 } | 172 } |
| 173 | 173 |
| 174 void ShadowRoot::detachLayoutTree(const AttachContext& context) { | 174 void ShadowRoot::detachLayoutTree(const AttachContext& context) { |
| 175 if (context.clearInvalidation) | 175 if (context.clearInvalidation) |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 346 ostream << "ShadowRootType::Open"; | 346 ostream << "ShadowRootType::Open"; |
| 347 break; | 347 break; |
| 348 case ShadowRootType::Closed: | 348 case ShadowRootType::Closed: |
| 349 ostream << "ShadowRootType::Closed"; | 349 ostream << "ShadowRootType::Closed"; |
| 350 break; | 350 break; |
| 351 } | 351 } |
| 352 return ostream; | 352 return ostream; |
| 353 } | 353 } |
| 354 | 354 |
| 355 } // namespace blink | 355 } // namespace blink |
| OLD | NEW |