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

Unified Diff: content/public/browser/web_contents_media_capture_id.h

Issue 2291893002: Let Contraints Controll Mute/Unmute Audio Local Playback For Desktop Sharing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove Debug Code Created 4 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 side-by-side diff with in-line comments
Download patch
Index: content/public/browser/web_contents_media_capture_id.h
diff --git a/content/public/browser/web_contents_media_capture_id.h b/content/public/browser/web_contents_media_capture_id.h
index 84d91dbe7da4595ef63eed60a67af8bf504e93e2..e159eeb23b031a5f863254ef7ab36c864455dd1a 100644
--- a/content/public/browser/web_contents_media_capture_id.h
+++ b/content/public/browser/web_contents_media_capture_id.h
@@ -21,10 +21,12 @@ struct CONTENT_EXPORT WebContentsMediaCaptureId {
WebContentsMediaCaptureId(int render_process_id,
int main_render_frame_id,
- bool enable_auto_throttling)
+ bool enable_auto_throttling,
+ bool mute_source)
: render_process_id(render_process_id),
main_render_frame_id(main_render_frame_id),
- enable_auto_throttling(enable_auto_throttling) {}
+ enable_auto_throttling(enable_auto_throttling),
+ mute_source(mute_source) {}
bool operator<(const WebContentsMediaCaptureId& other) const;
bool operator==(const WebContentsMediaCaptureId& other) const;
@@ -39,6 +41,7 @@ struct CONTENT_EXPORT WebContentsMediaCaptureId {
int main_render_frame_id = MSG_ROUTING_NONE;
bool enable_auto_throttling = false;
+ bool mute_source = false;
// Create WebContentsMediaCaptureId based on a string.
static WebContentsMediaCaptureId Parse(const std::string& str);
@@ -52,9 +55,15 @@ struct CONTENT_EXPORT WebContentsMediaCaptureId {
int* render_process_id,
int* main_render_frame_id);
- // Parses the media stream request |device_id| and returns true if both 1) the
- // format is valid, and 2) the throttling option is set to auto.
- static bool IsAutoThrottlingOptionSet(const std::string& device_id);
+ // Parses the media stream request |device_id| and returns true if the
+ // format is valid. |*auto_throttling| will be stored whether the |device_id|
+ // indicated auto throttling. |*mute_source| will stored whether |device_id|
+ // requests us to mute the source audio during sharing.
+ // The caller can pass nullptr for either |auto_throttling| or |mute_source|,
+ // if the value is uninteresting.
+ static bool ExtractOptions(const std::string& device_id,
miu 2016/09/07 21:10:03 Looking at the calls to this function, only one of
qiangchen 2016/09/09 23:32:08 Done.
+ bool* auto_throttling,
+ bool* mute_source);
};
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698