Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013, Opera Software ASA. All rights reserved. | 2 * Copyright (c) 2013, Opera Software ASA. 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 417 | 417 |
| 418 void VTTCue::createVTTNodeTree() | 418 void VTTCue::createVTTNodeTree() |
| 419 { | 419 { |
| 420 if (!m_vttNodeTree) | 420 if (!m_vttNodeTree) |
| 421 m_vttNodeTree = VTTParser::createDocumentFragmentFromCueText(document(), m_text); | 421 m_vttNodeTree = VTTParser::createDocumentFragmentFromCueText(document(), m_text); |
| 422 } | 422 } |
| 423 | 423 |
| 424 void VTTCue::copyVTTNodeToDOMTree(ContainerNode* vttNode, ContainerNode* parent) | 424 void VTTCue::copyVTTNodeToDOMTree(ContainerNode* vttNode, ContainerNode* parent) |
| 425 { | 425 { |
| 426 for (Node* node = vttNode->firstChild(); node; node = node->nextSibling()) { | 426 for (Node* node = vttNode->firstChild(); node; node = node->nextSibling()) { |
| 427 RefPtr<Node> clonedNode; | 427 RefPtrWillBeRawPtr<Node> clonedNode; |
|
haraken
2014/06/04 07:06:16
= nullptr
tkent
2014/06/04 08:03:25
Ditto.
| |
| 428 if (node->isVTTElement()) | 428 if (node->isVTTElement()) |
| 429 clonedNode = toVTTElement(node)->createEquivalentHTMLElement(documen t()); | 429 clonedNode = toVTTElement(node)->createEquivalentHTMLElement(documen t()); |
| 430 else | 430 else |
| 431 clonedNode = node->cloneNode(false); | 431 clonedNode = node->cloneNode(false); |
| 432 parent->appendChild(clonedNode); | 432 parent->appendChild(clonedNode); |
| 433 if (node->isContainerNode()) | 433 if (node->isContainerNode()) |
| 434 copyVTTNodeToDOMTree(toContainerNode(node), toContainerNode(clonedNo de)); | 434 copyVTTNodeToDOMTree(toContainerNode(node), toContainerNode(clonedNo de)); |
| 435 } | 435 } |
| 436 } | 436 } |
| 437 | 437 |
| (...skipping 660 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1098 | 1098 |
| 1099 void VTTCue::trace(Visitor* visitor) | 1099 void VTTCue::trace(Visitor* visitor) |
| 1100 { | 1100 { |
| 1101 visitor->trace(m_vttNodeTree); | 1101 visitor->trace(m_vttNodeTree); |
| 1102 visitor->trace(m_cueBackgroundBox); | 1102 visitor->trace(m_cueBackgroundBox); |
| 1103 visitor->trace(m_displayTree); | 1103 visitor->trace(m_displayTree); |
| 1104 TextTrackCue::trace(visitor); | 1104 TextTrackCue::trace(visitor); |
| 1105 } | 1105 } |
| 1106 | 1106 |
| 1107 } // namespace WebCore | 1107 } // namespace WebCore |
| OLD | NEW |