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

Side by Side Diff: content/browser/renderer_host/media/media_stream_manager.h

Issue 185863003: [Media] Add user gesture reporting for API calls to midi and media streams. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: try 2 Created 6 years, 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // MediaStreamManager is used to open/enumerate media capture devices (video 5 // MediaStreamManager is used to open/enumerate media capture devices (video
6 // supported now). Call flow: 6 // supported now). Call flow:
7 // 1. GenerateStream is called when a render process wants to use a capture 7 // 1. GenerateStream is called when a render process wants to use a capture
8 // device. 8 // device.
9 // 2. MediaStreamManager will ask MediaStreamUIController for permission to 9 // 2. MediaStreamManager will ask MediaStreamUIController for permission to
10 // use devices and for which device to use. 10 // use devices and for which device to use.
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 // GenerateStream opens new media devices according to |components|. It 90 // GenerateStream opens new media devices according to |components|. It
91 // creates a new request which is identified by a unique string that's 91 // creates a new request which is identified by a unique string that's
92 // returned to the caller. |render_process_id| and |render_view_id| refer to 92 // returned to the caller. |render_process_id| and |render_view_id| refer to
93 // the view where the infobar will appear to the user. 93 // the view where the infobar will appear to the user.
94 void GenerateStream(MediaStreamRequester* requester, 94 void GenerateStream(MediaStreamRequester* requester,
95 int render_process_id, 95 int render_process_id,
96 int render_view_id, 96 int render_view_id,
97 const ResourceContext::SaltCallback& sc, 97 const ResourceContext::SaltCallback& sc,
98 int page_request_id, 98 int page_request_id,
99 const StreamOptions& components, 99 const StreamOptions& components,
100 const GURL& security_origin); 100 const GURL& security_origin,
101 bool user_gesture);
101 102
102 void CancelRequest(int render_process_id, 103 void CancelRequest(int render_process_id,
103 int render_view_id, 104 int render_view_id,
104 int page_request_id); 105 int page_request_id);
105 106
106 // Cancel an open request identified by |label|. 107 // Cancel an open request identified by |label|.
107 virtual void CancelRequest(const std::string& label); 108 virtual void CancelRequest(const std::string& label);
108 109
109 // Cancel all requests for the given |render_process_id|. 110 // Cancel all requests for the given |render_process_id|.
110 void CancelAllRequests(int render_process_id); 111 void CancelAllRequests(int render_process_id);
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
363 364
364 bool use_fake_ui_; 365 bool use_fake_ui_;
365 scoped_ptr<FakeMediaStreamUIProxy> fake_ui_; 366 scoped_ptr<FakeMediaStreamUIProxy> fake_ui_;
366 367
367 DISALLOW_COPY_AND_ASSIGN(MediaStreamManager); 368 DISALLOW_COPY_AND_ASSIGN(MediaStreamManager);
368 }; 369 };
369 370
370 } // namespace content 371 } // namespace content
371 372
372 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MEDIA_STREAM_MANAGER_H_ 373 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MEDIA_STREAM_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698