Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(635)

Side by Side Diff: Source/platform/exported/WebMediaStreamTrack.cpp

Issue 569613002: Add the possibility to specify MediaStreamTrack::remote when creating a track. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 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 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 return *this; 77 return *this;
78 } 78 }
79 79
80 void WebMediaStreamTrack::initialize(const WebMediaStreamSource& source) 80 void WebMediaStreamTrack::initialize(const WebMediaStreamSource& source)
81 { 81 {
82 m_private = MediaStreamComponent::create(source); 82 m_private = MediaStreamComponent::create(source);
83 } 83 }
84 84
85 void WebMediaStreamTrack::initialize(const WebString& id, const WebMediaStreamSo urce& source) 85 void WebMediaStreamTrack::initialize(const WebString& id, const WebMediaStreamSo urce& source)
86 { 86 {
87 m_private = MediaStreamComponent::create(id, source); 87 initialize(id, source, true);
hta - Chromium 2014/09/24 10:07:33 This choice is strange, since it will make remote
88 }
89
90 void WebMediaStreamTrack::initialize(const WebString& id, const WebMediaStreamSo urce& source, bool remote)
91 {
92 m_private = MediaStreamComponent::create(id, source, remote);
88 } 93 }
89 94
90 void WebMediaStreamTrack::reset() 95 void WebMediaStreamTrack::reset()
91 { 96 {
92 m_private.reset(); 97 m_private.reset();
93 } 98 }
94 99
95 WebMediaStreamTrack::operator PassRefPtr<MediaStreamComponent>() const 100 WebMediaStreamTrack::operator PassRefPtr<MediaStreamComponent>() const
96 { 101 {
97 return m_private.get(); 102 return m_private.get();
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 m_private->setSourceProvider(provider); 150 m_private->setSourceProvider(provider);
146 #endif // ENABLE(WEB_AUDIO) 151 #endif // ENABLE(WEB_AUDIO)
147 } 152 }
148 153
149 void WebMediaStreamTrack::assign(const WebMediaStreamTrack& other) 154 void WebMediaStreamTrack::assign(const WebMediaStreamTrack& other)
150 { 155 {
151 m_private = other.m_private; 156 m_private = other.m_private;
152 } 157 }
153 158
154 } // namespace blink 159 } // namespace blink
OLDNEW
« no previous file with comments | « Source/modules/mediastream/MediaStreamTrack.idl ('k') | Source/platform/mediastream/MediaStreamComponent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698