| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef SourceBufferTrackBaseSupplement_h | 5 #ifndef SourceBufferTrackBaseSupplement_h |
| 6 #define SourceBufferTrackBaseSupplement_h | 6 #define SourceBufferTrackBaseSupplement_h |
| 7 | 7 |
| 8 #include "platform/Supplementable.h" | 8 #include "platform/Supplementable.h" |
| 9 #include "wtf/Allocator.h" | 9 #include "platform/wtf/Allocator.h" |
| 10 | 10 |
| 11 namespace blink { | 11 namespace blink { |
| 12 | 12 |
| 13 class TrackBase; | 13 class TrackBase; |
| 14 class SourceBuffer; | 14 class SourceBuffer; |
| 15 | 15 |
| 16 class SourceBufferTrackBaseSupplement | 16 class SourceBufferTrackBaseSupplement |
| 17 : public GarbageCollected<SourceBufferTrackBaseSupplement>, | 17 : public GarbageCollected<SourceBufferTrackBaseSupplement>, |
| 18 public Supplement<TrackBase> { | 18 public Supplement<TrackBase> { |
| 19 USING_GARBAGE_COLLECTED_MIXIN(SourceBufferTrackBaseSupplement); | 19 USING_GARBAGE_COLLECTED_MIXIN(SourceBufferTrackBaseSupplement); |
| 20 | 20 |
| 21 public: | 21 public: |
| 22 static SourceBuffer* sourceBuffer(TrackBase&); | 22 static SourceBuffer* sourceBuffer(TrackBase&); |
| 23 static void SetSourceBuffer(TrackBase&, SourceBuffer*); | 23 static void SetSourceBuffer(TrackBase&, SourceBuffer*); |
| 24 | 24 |
| 25 DECLARE_VIRTUAL_TRACE(); | 25 DECLARE_VIRTUAL_TRACE(); |
| 26 | 26 |
| 27 private: | 27 private: |
| 28 static SourceBufferTrackBaseSupplement& From(TrackBase&); | 28 static SourceBufferTrackBaseSupplement& From(TrackBase&); |
| 29 static SourceBufferTrackBaseSupplement* FromIfExists(TrackBase&); | 29 static SourceBufferTrackBaseSupplement* FromIfExists(TrackBase&); |
| 30 | 30 |
| 31 Member<SourceBuffer> source_buffer_; | 31 Member<SourceBuffer> source_buffer_; |
| 32 }; | 32 }; |
| 33 | 33 |
| 34 } // namespace blink | 34 } // namespace blink |
| 35 | 35 |
| 36 #endif | 36 #endif |
| OLD | NEW |