Index: chrome/browser/extensions/api/cryptotoken_private/cryptotoken_private_api.h |
diff --git a/chrome/browser/extensions/api/cryptotoken_private/cryptotoken_private_api.h b/chrome/browser/extensions/api/cryptotoken_private/cryptotoken_private_api.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..565a85b4bf007779e4c97c757356a2ff7c8a581e |
--- /dev/null |
+++ b/chrome/browser/extensions/api/cryptotoken_private/cryptotoken_private_api.h |
@@ -0,0 +1,44 @@ |
+// Copyright 2014 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. |
+ |
+#ifndef CHROME_BROWSER_EXTENSIONS_API_CRYPTOTOKEN_PRIVATE_CRYPTOTOKEN_PRIVATE_API_H_ |
+#define CHROME_BROWSER_EXTENSIONS_API_CRYPTOTOKEN_PRIVATE_CRYPTOTOKEN_PRIVATE_API_H_ |
+ |
+#include <string> |
+ |
+#include "base/basictypes.h" |
+#include "base/memory/scoped_ptr.h" |
+#include "chrome/browser/extensions/chrome_extension_function_details.h" |
+#include "chrome/common/extensions/api/cryptotoken_private.h" |
+#include "extensions/browser/extension_function.h" |
+ |
+// Implementations for chrome.cryptotokenPrivate API functions. |
+ |
+namespace infobars { |
+class InfoBar; |
+} |
+ |
+namespace extensions { |
+namespace api { |
+ |
+class CryptotokenPrivateRequestPermissionFunction |
+ : public UIThreadExtensionFunction { |
+ public: |
+ CryptotokenPrivateRequestPermissionFunction(); |
+ DECLARE_EXTENSION_FUNCTION("cryptotokenPrivate.requestPermission", |
+ CRYPTOTOKENPRIVATE_REQUESTPERMISSION) |
+ protected: |
+ virtual ~CryptotokenPrivateRequestPermissionFunction() override {} |
+ virtual ResponseAction Run() override; |
+ |
+ private: |
+ ChromeExtensionFunctionDetails chrome_details_; |
+ |
+ void OnInfobarResponse(cryptotoken_private::PermissionResult result); |
+}; |
+ |
+} // namespace api |
+} // namespace extensions |
+ |
+#endif // CHROME_BROWSER_EXTENSIONS_API_CRYPTOTOKEN_PRIVATE_CRYPTOTOKEN_PRIVATE_API_H_ |