Index: chrome/common/extensions/api/tab_capture.idl |
diff --git a/chrome/common/extensions/api/tab_capture.idl b/chrome/common/extensions/api/tab_capture.idl |
index c6489d6f6980c167c3b898864692979588bec2d5..7d313bcb6c75bfacb333d5b0781ecc4a216a77ae 100644 |
--- a/chrome/common/extensions/api/tab_capture.idl |
+++ b/chrome/common/extensions/api/tab_capture.idl |
@@ -39,6 +39,7 @@ namespace tabCapture { |
boolean? video; |
MediaStreamConstraint? audioConstraints; |
MediaStreamConstraint? videoConstraints; |
+ [nodoc] DOMString? presentationId; |
}; |
callback GetTabMediaCallback = |
@@ -66,6 +67,33 @@ namespace tabCapture { |
// to prevent redundant requests for the same tab). |
// |callback| : Callback invoked with CaptureInfo[] for captured tabs. |
static void getCapturedTabs(GetCapturedTabsCallback callback); |
+ |
+ // Creates an off-screen tab and navigates it to the given |startUrl|. |
+ // Then, capture is started and a MediaStream is returned via |callback|. |
+ // |
+ // Off-screen tabs are isolated from the user's normal browser experience. |
+ // They do not show up in the browser window or tab strip, nor are they |
+ // visible to extensions (e.g., via the chrome.tabs.* APIs). |
+ // |
+ // An off-screen tab remains alive until one of three events occurs: 1. All |
+ // MediaStreams providing its captured content are closed; 2. the page |
+ // self-closes (e.g., via window.close()); 3. the extension that called |
+ // captureOffscreenTab() is unloaded. |
+ // |
+ // Sandboxing: The off-screen tab does not have any access whatsoever to the |
+ // local user profile (including cookies, HTTP auth, etc.). Instead, it is |
+ // provided its own sandboxed profile. Also, it cannot access any |
+ // interactive resources such as keyboard/mouse input, media recording |
+ // devices (e.g., web cams), copy/paste to/from the system clipboard, etc. |
+ // |
+ // Note: This is a new API, currently only available in Canary/Dev channel, |
+ // and may change without notice. |
+ // |
+ // |options| : Constraints for the capture and returned MediaStream. |
+ // |callback| : <code>null</code> on error. |
+ static void captureOffscreenTab(DOMString startUrl, |
+ CaptureOptions options, |
+ GetTabMediaCallback callback); |
}; |
interface Events { |