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

Unified Diff: content/renderer/media/media_stream_impl.cc

Issue 88283002: Reland review 34393006: Refactor MediaStreamManager to not output real device id. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/media/media_stream_impl.cc
diff --git a/content/renderer/media/media_stream_impl.cc b/content/renderer/media/media_stream_impl.cc
index 7362f9a32f4229d8cde882974adfad21d31ec00c..25b6dea557ba0d1e24c8c016b44cb0a4e77a6cc1 100644
--- a/content/renderer/media/media_stream_impl.cc
+++ b/content/renderer/media/media_stream_impl.cc
@@ -449,12 +449,6 @@ void MediaStreamImpl::CreateWebKitSourceVector(
blink::WebVector<blink::WebMediaStreamSource>& webkit_sources) {
CHECK_EQ(devices.size(), webkit_sources.size());
for (size_t i = 0; i < devices.size(); ++i) {
- const char* track_type =
- (type == blink::WebMediaStreamSource::TypeAudio) ? "a" : "v";
- std::string source_id = base::StringPrintf("%s%s%u", label.c_str(),
- track_type,
- static_cast<unsigned int>(i));
-
const blink::WebMediaStreamSource* existing_source =
FindLocalSource(devices[i]);
if (existing_source) {
@@ -464,7 +458,7 @@ void MediaStreamImpl::CreateWebKitSourceVector(
continue;
}
webkit_sources[i].initialize(
- UTF8ToUTF16(source_id),
+ UTF8ToUTF16(devices[i].device.id),
type,
UTF8ToUTF16(devices[i].device.name));
MediaStreamSourceExtraData* source_extra_data(
« no previous file with comments | « content/public/common/media_stream_request.cc ('k') | content/renderer/media/mock_media_stream_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698