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 | 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 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 // Since we've moved to a new parent, we may now be able to load. | 73 // Since we've moved to a new parent, we may now be able to load. |
74 scheduleLoad(); | 74 scheduleLoad(); |
75 | 75 |
76 HTMLElement::insertedInto(insertionPoint); | 76 HTMLElement::insertedInto(insertionPoint); |
77 HTMLMediaElement* parent = mediaElement(); | 77 HTMLMediaElement* parent = mediaElement(); |
78 if (insertionPoint == parent) | 78 if (insertionPoint == parent) |
79 parent->didAddTrackElement(this); | 79 parent->didAddTrackElement(this); |
80 return InsertionDone; | 80 return InsertionDone; |
81 } | 81 } |
82 | 82 |
83 void HTMLTrackElement::removedFrom(ContainerNode* insertionPoint) | 83 void HTMLTrackElement::removedFrom(ContainerNode* insertionPoint, Node* next) |
84 { | 84 { |
85 if (!parentNode() && isHTMLMediaElement(*insertionPoint)) | 85 if (!parentNode() && isHTMLMediaElement(*insertionPoint)) |
86 toHTMLMediaElement(insertionPoint)->didRemoveTrackElement(this); | 86 toHTMLMediaElement(insertionPoint)->didRemoveTrackElement(this); |
87 HTMLElement::removedFrom(insertionPoint); | 87 HTMLElement::removedFrom(insertionPoint, next); |
88 } | 88 } |
89 | 89 |
90 void HTMLTrackElement::parseAttribute(const QualifiedName& name, const AtomicStr
ing& oldValue, const AtomicString& value) | 90 void HTMLTrackElement::parseAttribute(const QualifiedName& name, const AtomicStr
ing& oldValue, const AtomicString& value) |
91 { | 91 { |
92 if (name == srcAttr) { | 92 if (name == srcAttr) { |
93 if (!value.isEmpty()) | 93 if (!value.isEmpty()) |
94 scheduleLoad(); | 94 scheduleLoad(); |
95 else if (m_track) | 95 else if (m_track) |
96 m_track->removeAllCues(); | 96 m_track->removeAllCues(); |
97 | 97 |
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
329 } | 329 } |
330 | 330 |
331 DEFINE_TRACE(HTMLTrackElement) | 331 DEFINE_TRACE(HTMLTrackElement) |
332 { | 332 { |
333 visitor->trace(m_track); | 333 visitor->trace(m_track); |
334 visitor->trace(m_loader); | 334 visitor->trace(m_loader); |
335 HTMLElement::trace(visitor); | 335 HTMLElement::trace(visitor); |
336 } | 336 } |
337 | 337 |
338 } | 338 } |
OLD | NEW |