| Index: chrome/browser/extensions/api/tab_capture/tab_capture_api.h
|
| diff --git a/chrome/browser/extensions/api/tab_capture/tab_capture_api.h b/chrome/browser/extensions/api/tab_capture/tab_capture_api.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..c5012d5ff295cbac16aa4400610f4d5b4c3e0844
|
| --- /dev/null
|
| +++ b/chrome/browser/extensions/api/tab_capture/tab_capture_api.h
|
| @@ -0,0 +1,60 @@
|
| +// Copyright (c) 2012 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +// Defines the Chrome Extensions Tab Capture API functions for accessing
|
| +// tab media streams.
|
| +
|
| +#ifndef CHROME_BROWSER_EXTENSIONS_API_TAB_CAPTURE_TAB_CAPTURE_API_H_
|
| +#define CHROME_BROWSER_EXTENSIONS_API_TAB_CAPTURE_TAB_CAPTURE_API_H_
|
| +
|
| +#include "chrome/browser/extensions/api/api_function.h"
|
| +#include "chrome/common/extensions/api/experimental_tab_capture.h"
|
| +
|
| +namespace extensions {
|
| +
|
| +class TabCaptureAsyncApiFunction : public AsyncApiFunction {
|
| + public:
|
| + TabCaptureAsyncApiFunction();
|
| +
|
| + protected:
|
| + virtual ~TabCaptureAsyncApiFunction();
|
| +
|
| + // AsyncApiFunction:
|
| + virtual bool Respond() OVERRIDE;
|
| +};
|
| +
|
| +class TabCaptureGetTabMediaFunction : public TabCaptureAsyncApiFunction {
|
| + public:
|
| + DECLARE_EXTENSION_FUNCTION_NAME("experimental.tabCapture.getTabMedia");
|
| + TabCaptureGetTabMediaFunction();
|
| +
|
| + protected:
|
| + virtual ~TabCaptureGetTabMediaFunction();
|
| +
|
| + // AsyncApiFunction:
|
| + virtual bool Prepare() OVERRIDE;
|
| + virtual void Work() OVERRIDE;
|
| +
|
| + private:
|
| + scoped_ptr<api::experimental_tab_capture::GetTabMedia::Params> params_;
|
| +};
|
| +
|
| +class TabCaptureGetCapturedTabsFunction : public TabCaptureAsyncApiFunction {
|
| + public:
|
| + DECLARE_EXTENSION_FUNCTION_NAME("experimental.tabCapture.getCapturedTabs");
|
| + TabCaptureGetCapturedTabsFunction();
|
| +
|
| + protected:
|
| + virtual ~TabCaptureGetCapturedTabsFunction();
|
| +
|
| + // AsyncApiFunction:
|
| + virtual bool Prepare() OVERRIDE;
|
| + virtual void Work() OVERRIDE;
|
| +
|
| + private:
|
| +};
|
| +
|
| +} // namespace extensions
|
| +
|
| +#endif // CHROME_BROWSER_EXTENSIONS_API_TAB_CAPTURE_TAB_CAPTURE_API_H_
|
|
|