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

Unified Diff: content/browser/renderer_host/media/media_stream_manager.cc

Issue 10177008: Shift media_stream::StreamOptions to align with the new getUserMedia spec (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase Created 8 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/media/media_stream_manager.cc
diff --git a/content/browser/renderer_host/media/media_stream_manager.cc b/content/browser/renderer_host/media/media_stream_manager.cc
index 994725b9308187c29f8c5d4b440e5fe661829e83..9771e25ac6c96fee1a4c75c6839c43d7580855dd 100644
--- a/content/browser/renderer_host/media/media_stream_manager.cc
+++ b/content/browser/renderer_host/media/media_stream_manager.cc
@@ -45,10 +45,10 @@ static std::string RandomLabel() {
static bool Requested(const StreamOptions& options,
MediaStreamType stream_type) {
if (stream_type == content::MEDIA_STREAM_DEVICE_TYPE_VIDEO_CAPTURE &&
- (options.video_option != StreamOptions::kNoCamera)) {
+ options.video) {
return true;
} else if (stream_type == content::MEDIA_STREAM_DEVICE_TYPE_AUDIO_CAPTURE &&
- options.audio == true) {
+ options.audio) {
return true;
}
return false;
@@ -75,7 +75,7 @@ struct MediaStreamManager::DeviceRequest {
state(content::NUM_MEDIA_STREAM_DEVICE_TYPES, kNotRequested),
type(kGenerateStream) {
options.audio = false;
- options.video_option = StreamOptions::kNoCamera;
+ options.video = false;
}
DeviceRequest(MediaStreamRequester* requester,
@@ -228,7 +228,7 @@ void MediaStreamManager::EnumerateDevices(
if (type == content::MEDIA_STREAM_DEVICE_TYPE_AUDIO_CAPTURE)
options.audio = true;
else
- options.video_option = StreamOptions::kFacingUser;
+ options.video = true;
DeviceRequest new_request = DeviceRequest(requester, options);
new_request.type = DeviceRequest::kEnumerateDevices;
@@ -252,7 +252,7 @@ void MediaStreamManager::OpenDevice(
if (type == content::MEDIA_STREAM_DEVICE_TYPE_AUDIO_CAPTURE)
options.audio = true;
else
- options.video_option = StreamOptions::kFacingUser;
+ options.video = true;
DeviceRequest new_request = DeviceRequest(requester, options);
new_request.type = DeviceRequest::kOpenDevice;

Powered by Google App Engine
This is Rietveld 408576698