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

Unified Diff: chrome/browser/extensions/api/cryptotoken_private/cryptotoken_private_api.h

Issue 766303003: A private API for the cryptotoken component extension. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: New permission has no ui string, skip in tests Created 6 years 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 side-by-side diff with in-line comments
Download patch
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_
« no previous file with comments | « chrome/app/theme/theme_resources.grd ('k') | chrome/browser/extensions/api/cryptotoken_private/cryptotoken_private_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698