Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / chrome / common / extensions / api / webrtc_desktop_capture_private.idl
blobd71f518b164782831054d21473360a2075403a04
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 // Use the <code>chrome.webrtcDesktopCapturePrivate</code> API to capture
6 // desktop media requested from a WebView.
7 namespace webrtcDesktopCapturePrivate {
8 dictionary RequestInfo {
9 // The guest process id for the requester.
10 long guestProcessId;
12 // The webview render frame id for the requester.
13 long guestRenderFrameId;
16 enum DesktopCaptureSourceType {
17 screen,
18 window,
19 tab
22 callback chooseDesktopMediaCallback = void (DOMString streamId);
24 interface Functions {
25 // Shows desktop media picker UI with the specified set of sources.
26 static long chooseDesktopMedia(DesktopCaptureSourceType[] sources,
27 RequestInfo request,
28 chooseDesktopMediaCallback callback);
30 // Hides desktop media picker dialog shown by chooseDesktopMedia().
31 static void cancelChooseDesktopMedia(long desktopMediaRequestId);