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 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
106 ASSERT(m_cachedCueData == resource); | 106 ASSERT(m_cachedCueData == resource); |
107 | 107 |
108 if (!resource->resourceBuffer()) | 108 if (!resource->resourceBuffer()) |
109 return; | 109 return; |
110 | 110 |
111 processNewCueData(resource); | 111 processNewCueData(resource); |
112 } | 112 } |
113 | 113 |
114 void TextTrackLoader::corsPolicyPreventedLoad() | 114 void TextTrackLoader::corsPolicyPreventedLoad() |
115 { | 115 { |
116 DEFINE_STATIC_LOCAL(String, consoleMessage, (ASCIILiteral("Cross-origin text
track load denied by Cross-Origin Resource Sharing policy."))); | 116 DEFINE_STATIC_LOCAL(String, consoleMessage, ("Cross-origin text track load d
enied by Cross-Origin Resource Sharing policy.")); |
117 Document* document = toDocument(m_scriptExecutionContext); | 117 Document* document = toDocument(m_scriptExecutionContext); |
118 document->addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, consol
eMessage); | 118 document->addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, consol
eMessage); |
119 m_state = Failed; | 119 m_state = Failed; |
120 } | 120 } |
121 | 121 |
122 void TextTrackLoader::notifyFinished(Resource* resource) | 122 void TextTrackLoader::notifyFinished(Resource* resource) |
123 { | 123 { |
124 ASSERT(m_cachedCueData == resource); | 124 ASSERT(m_cachedCueData == resource); |
125 | 125 |
126 Document* document = toDocument(m_scriptExecutionContext); | 126 Document* document = toDocument(m_scriptExecutionContext); |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 #if ENABLE(WEBVTT_REGIONS) | 214 #if ENABLE(WEBVTT_REGIONS) |
215 void TextTrackLoader::getNewRegions(Vector<RefPtr<TextTrackRegion> >& outputRegi
ons) | 215 void TextTrackLoader::getNewRegions(Vector<RefPtr<TextTrackRegion> >& outputRegi
ons) |
216 { | 216 { |
217 ASSERT(m_cueParser); | 217 ASSERT(m_cueParser); |
218 if (m_cueParser) | 218 if (m_cueParser) |
219 m_cueParser->getNewRegions(outputRegions); | 219 m_cueParser->getNewRegions(outputRegions); |
220 } | 220 } |
221 #endif | 221 #endif |
222 } | 222 } |
223 | 223 |
OLD | NEW |