| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 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 are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 return ended; | 106 return ended; |
| 107 } | 107 } |
| 108 | 108 |
| 109 MediaSource* MediaSource::create(ExecutionContext* context) { | 109 MediaSource* MediaSource::create(ExecutionContext* context) { |
| 110 MediaSource* mediaSource = new MediaSource(context); | 110 MediaSource* mediaSource = new MediaSource(context); |
| 111 mediaSource->suspendIfNeeded(); | 111 mediaSource->suspendIfNeeded(); |
| 112 return mediaSource; | 112 return mediaSource; |
| 113 } | 113 } |
| 114 | 114 |
| 115 MediaSource::MediaSource(ExecutionContext* context) | 115 MediaSource::MediaSource(ExecutionContext* context) |
| 116 : ActiveScriptWrappable(this), | 116 : ActiveScriptWrappable<MediaSource>(this), |
| 117 SuspendableObject(context), | 117 SuspendableObject(context), |
| 118 m_readyState(closedKeyword()), | 118 m_readyState(closedKeyword()), |
| 119 m_asyncEventQueue(GenericEventQueue::create(this)), | 119 m_asyncEventQueue(GenericEventQueue::create(this)), |
| 120 m_attachedElement(nullptr), | 120 m_attachedElement(nullptr), |
| 121 m_sourceBuffers(SourceBufferList::create(getExecutionContext(), | 121 m_sourceBuffers(SourceBufferList::create(getExecutionContext(), |
| 122 m_asyncEventQueue.get())), | 122 m_asyncEventQueue.get())), |
| 123 m_activeSourceBuffers(SourceBufferList::create(getExecutionContext(), | 123 m_activeSourceBuffers(SourceBufferList::create(getExecutionContext(), |
| 124 m_asyncEventQueue.get())), | 124 m_asyncEventQueue.get())), |
| 125 m_liveSeekableRange(TimeRanges::create()), | 125 m_liveSeekableRange(TimeRanges::create()), |
| 126 m_addedToRegistryCounter(0) { | 126 m_addedToRegistryCounter(0) { |
| (...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 815 event->setTarget(this); | 815 event->setTarget(this); |
| 816 | 816 |
| 817 m_asyncEventQueue->enqueueEvent(event); | 817 m_asyncEventQueue->enqueueEvent(event); |
| 818 } | 818 } |
| 819 | 819 |
| 820 URLRegistry& MediaSource::registry() const { | 820 URLRegistry& MediaSource::registry() const { |
| 821 return MediaSourceRegistry::registry(); | 821 return MediaSourceRegistry::registry(); |
| 822 } | 822 } |
| 823 | 823 |
| 824 } // namespace blink | 824 } // namespace blink |
| OLD | NEW |