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

Unified Diff: chrome/browser/extensions/extension_webstore_private_api.h

Issue 8772031: Add a JS API for detecting WebGL availability. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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/extension_webstore_private_api.h
===================================================================
--- chrome/browser/extensions/extension_webstore_private_api.h (revision 112998)
+++ chrome/browser/extensions/extension_webstore_private_api.h (working copy)
@@ -13,6 +13,7 @@
#include "chrome/browser/extensions/webstore_install_helper.h"
#include "chrome/browser/extensions/webstore_installer.h"
#include "chrome/common/net/gaia/google_service_auth_error.h"
+#include "content/browser/gpu/gpu_data_manager.h"
#include "content/public/browser/notification_observer.h"
#include "content/public/browser/notification_registrar.h"
@@ -159,4 +160,19 @@
DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.setStoreLogin");
};
+class GetWebGLStatusFunction : public AsyncExtensionFunction,
+ public GpuDataManager::Observer {
+ public:
+ GetWebGLStatusFunction();
+ virtual void OnGpuInfoUpdate() OVERRIDE;
+
+ protected:
+ virtual ~GetWebGLStatusFunction();
+ virtual bool RunImpl() OVERRIDE;
+
+ static bool IsWebGLAllowed(GpuDataManager* manager);
+
+ DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.getWebGLStatus");
+};
+
#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_WEBSTORE_PRIVATE_API_H_

Powered by Google App Engine
This is Rietveld 408576698