| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Ericsson AB. All rights reserved. | 2 * Copyright (C) 2011 Ericsson AB. All rights reserved. |
| 3 * Copyright (C) 2012 Google Inc. All rights reserved. | 3 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 30 */ | 30 */ |
| 31 | 31 |
| 32 #include "platform/mediastream/MediaStreamCenter.h" | 32 #include "platform/mediastream/MediaStreamCenter.h" |
| 33 | 33 |
| 34 #include <memory> | 34 #include <memory> |
| 35 | 35 |
| 36 #include "platform/mediastream/MediaStreamDescriptor.h" | 36 #include "platform/mediastream/MediaStreamDescriptor.h" |
| 37 #include "platform/mediastream/MediaStreamWebAudioSource.h" | 37 #include "platform/mediastream/MediaStreamWebAudioSource.h" |
| 38 #include "platform/wtf/Assertions.h" |
| 39 #include "platform/wtf/PtrUtil.h" |
| 38 #include "public/platform/Platform.h" | 40 #include "public/platform/Platform.h" |
| 39 #include "public/platform/WebAudioSourceProvider.h" | 41 #include "public/platform/WebAudioSourceProvider.h" |
| 40 #include "public/platform/WebMediaStream.h" | 42 #include "public/platform/WebMediaStream.h" |
| 41 #include "public/platform/WebMediaStreamCenter.h" | 43 #include "public/platform/WebMediaStreamCenter.h" |
| 42 #include "public/platform/WebMediaStreamTrack.h" | 44 #include "public/platform/WebMediaStreamTrack.h" |
| 43 #include "wtf/Assertions.h" | |
| 44 #include "wtf/PtrUtil.h" | |
| 45 | 45 |
| 46 namespace blink { | 46 namespace blink { |
| 47 | 47 |
| 48 MediaStreamCenter& MediaStreamCenter::Instance() { | 48 MediaStreamCenter& MediaStreamCenter::Instance() { |
| 49 ASSERT(IsMainThread()); | 49 ASSERT(IsMainThread()); |
| 50 DEFINE_STATIC_LOCAL(MediaStreamCenter, center, ()); | 50 DEFINE_STATIC_LOCAL(MediaStreamCenter, center, ()); |
| 51 return center; | 51 return center; |
| 52 } | 52 } |
| 53 | 53 |
| 54 MediaStreamCenter::MediaStreamCenter() | 54 MediaStreamCenter::MediaStreamCenter() |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 } | 141 } |
| 142 | 142 |
| 143 void MediaStreamCenter::StopLocalMediaStream(const WebMediaStream& web_stream) { | 143 void MediaStreamCenter::StopLocalMediaStream(const WebMediaStream& web_stream) { |
| 144 MediaStreamDescriptor* stream = web_stream; | 144 MediaStreamDescriptor* stream = web_stream; |
| 145 MediaStreamDescriptorClient* client = stream->Client(); | 145 MediaStreamDescriptorClient* client = stream->Client(); |
| 146 if (client) | 146 if (client) |
| 147 client->StreamEnded(); | 147 client->StreamEnded(); |
| 148 } | 148 } |
| 149 | 149 |
| 150 } // namespace blink | 150 } // namespace blink |
| OLD | NEW |