| 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 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 if (name == srcAttr) { | 86 if (name == srcAttr) { |
| 87 if (!params.new_value.IsEmpty()) | 87 if (!params.new_value.IsEmpty()) |
| 88 ScheduleLoad(); | 88 ScheduleLoad(); |
| 89 else if (track_) | 89 else if (track_) |
| 90 track_->RemoveAllCues(); | 90 track_->RemoveAllCues(); |
| 91 | 91 |
| 92 // 4.8.10.12.3 Sourcing out-of-band text tracks | 92 // 4.8.10.12.3 Sourcing out-of-band text tracks |
| 93 // As the kind, label, and srclang attributes are set, changed, or removed, | 93 // As the kind, label, and srclang attributes are set, changed, or removed, |
| 94 // the text track must update accordingly... | 94 // the text track must update accordingly... |
| 95 } else if (name == kindAttr) { | 95 } else if (name == kindAttr) { |
| 96 AtomicString lower_case_value = params.new_value.Lower(); | 96 AtomicString lower_case_value = params.new_value.DeprecatedLower(); |
| 97 // 'missing value default' ("subtitles") | 97 // 'missing value default' ("subtitles") |
| 98 if (lower_case_value.IsNull()) | 98 if (lower_case_value.IsNull()) |
| 99 lower_case_value = TextTrack::SubtitlesKeyword(); | 99 lower_case_value = TextTrack::SubtitlesKeyword(); |
| 100 // 'invalid value default' ("metadata") | 100 // 'invalid value default' ("metadata") |
| 101 else if (!TextTrack::IsValidKindKeyword(lower_case_value)) | 101 else if (!TextTrack::IsValidKindKeyword(lower_case_value)) |
| 102 lower_case_value = TextTrack::MetadataKeyword(); | 102 lower_case_value = TextTrack::MetadataKeyword(); |
| 103 | 103 |
| 104 track()->SetKind(lower_case_value); | 104 track()->SetKind(lower_case_value); |
| 105 } else if (name == labelAttr) { | 105 } else if (name == labelAttr) { |
| 106 track()->SetLabel(params.new_value); | 106 track()->SetLabel(params.new_value); |
| (...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 339 return nullptr; | 339 return nullptr; |
| 340 } | 340 } |
| 341 | 341 |
| 342 DEFINE_TRACE(HTMLTrackElement) { | 342 DEFINE_TRACE(HTMLTrackElement) { |
| 343 visitor->Trace(track_); | 343 visitor->Trace(track_); |
| 344 visitor->Trace(loader_); | 344 visitor->Trace(loader_); |
| 345 HTMLElement::Trace(visitor); | 345 HTMLElement::Trace(visitor); |
| 346 } | 346 } |
| 347 | 347 |
| 348 } // namespace blink | 348 } // namespace blink |
| OLD | NEW |