| OLD | NEW | 
|---|
| 1 /* | 1 /* | 
| 2  * Copyright (C) 2011 Google Inc. All Rights Reserved. | 2  * Copyright (C) 2011 Google Inc. All Rights Reserved. | 
| 3  * Copyright (C) 2012 Apple Inc. All rights reserved. | 3  * Copyright (C) 2012 Apple 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 | 6  * modification, are permitted provided that the following conditions | 
| 7  * are met: | 7  * are met: | 
| 8  * 1. Redistributions of source code must retain the above copyright | 8  * 1. 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  * 2. Redistributions in binary form must reproduce the above copyright | 10  * 2. Redistributions in binary form must reproduce the above copyright | 
| (...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 326         } | 326         } | 
| 327     } | 327     } | 
| 328     return 0; | 328     return 0; | 
| 329 } | 329 } | 
| 330 | 330 | 
| 331 bool TreeScope::applyAuthorStyles() const | 331 bool TreeScope::applyAuthorStyles() const | 
| 332 { | 332 { | 
| 333     return !rootNode()->isShadowRoot() || toShadowRoot(rootNode())->applyAuthorS
     tyles(); | 333     return !rootNode()->isShadowRoot() || toShadowRoot(rootNode())->applyAuthorS
     tyles(); | 
| 334 } | 334 } | 
| 335 | 335 | 
| 336 void TreeScope::adoptIfNeeded(Node* node) | 336 void TreeScope::adoptIfNeeded(Node& node) | 
| 337 { | 337 { | 
| 338     ASSERT(this); | 338     ASSERT(this); | 
| 339     ASSERT(node); | 339     ASSERT(!node.isDocumentNode()); | 
| 340     ASSERT(!node->isDocumentNode()); | 340     ASSERT_WITH_SECURITY_IMPLICATION(!node.m_deletionHasBegun); | 
| 341     ASSERT_WITH_SECURITY_IMPLICATION(!node->m_deletionHasBegun); | 341     TreeScopeAdopter adopter(node, *this); | 
| 342     TreeScopeAdopter adopter(node, this); |  | 
| 343     if (adopter.needsScopeChange()) | 342     if (adopter.needsScopeChange()) | 
| 344         adopter.execute(); | 343         adopter.execute(); | 
| 345 } | 344 } | 
| 346 | 345 | 
| 347 static Element* focusedFrameOwnerElement(Frame* focusedFrame, Frame* currentFram
     e) | 346 static Element* focusedFrameOwnerElement(Frame* focusedFrame, Frame* currentFram
     e) | 
| 348 { | 347 { | 
| 349     for (; focusedFrame; focusedFrame = focusedFrame->tree().parent()) { | 348     for (; focusedFrame; focusedFrame = focusedFrame->tree().parent()) { | 
| 350         if (focusedFrame->tree().parent() == currentFrame) | 349         if (focusedFrame->tree().parent() == currentFrame) | 
| 351             return focusedFrame->ownerElement(); | 350             return focusedFrame->ownerElement(); | 
| 352     } | 351     } | 
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 491             result = element; | 490             result = element; | 
| 492         for (ShadowRoot* shadowRoot = element->youngestShadowRoot(); shadowRoot;
      shadowRoot = shadowRoot->olderShadowRoot()) { | 491         for (ShadowRoot* shadowRoot = element->youngestShadowRoot(); shadowRoot;
      shadowRoot = shadowRoot->olderShadowRoot()) { | 
| 493             if (Element* shadowResult = shadowRoot->getElementByAccessKey(key)) | 492             if (Element* shadowResult = shadowRoot->getElementByAccessKey(key)) | 
| 494                 result = shadowResult; | 493                 result = shadowResult; | 
| 495         } | 494         } | 
| 496     } | 495     } | 
| 497     return result; | 496     return result; | 
| 498 } | 497 } | 
| 499 | 498 | 
| 500 } // namespace WebCore | 499 } // namespace WebCore | 
| OLD | NEW | 
|---|