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

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

Issue 10071035: RefCounted types should not have public destructors, chrome/browser/extensions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Compile fix Created 8 years, 8 months 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
diff --git a/chrome/browser/extensions/extension_webstore_private_api.h b/chrome/browser/extensions/extension_webstore_private_api.h
index a4ea8d01a25dc408a444656226b70477e0322080..912f9d70c7a7cf0dd5f0581092612ba836f1a6c8 100644
--- a/chrome/browser/extensions/extension_webstore_private_api.h
+++ b/chrome/browser/extensions/extension_webstore_private_api.h
@@ -48,15 +48,19 @@ class WebstorePrivateApi {
class InstallBundleFunction : public AsyncExtensionFunction,
public extensions::BundleInstaller::Delegate {
public:
+ DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.installBundle");
+
InstallBundleFunction();
- // BundleInstaller::Delegate implementation.
+ // BundleInstaller::Delegate:
virtual void OnBundleInstallApproved() OVERRIDE;
virtual void OnBundleInstallCanceled(bool user_initiated) OVERRIDE;
virtual void OnBundleInstallCompleted() OVERRIDE;
protected:
virtual ~InstallBundleFunction();
+
+ // ExtensionFunction:
virtual bool RunImpl() OVERRIDE;
// Reads the extension |details| into |items|.
@@ -65,7 +69,6 @@ class InstallBundleFunction : public AsyncExtensionFunction,
private:
scoped_refptr<extensions::BundleInstaller> bundle_;
- DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.installBundle");
};
class BeginInstallWithManifestFunction
@@ -73,7 +76,7 @@ class BeginInstallWithManifestFunction
public ExtensionInstallUI::Delegate,
public WebstoreInstallHelper::Delegate {
public:
- BeginInstallWithManifestFunction();
+ DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.beginInstallWithManifest3");
// Result codes for the return value. If you change this, make sure to
// update the description for the beginInstallWithManifest3 callback in
@@ -103,7 +106,9 @@ class BeginInstallWithManifestFunction
INVALID_ICON_URL
};
- // Implementing WebstoreInstallHelper::Delegate interface.
+ BeginInstallWithManifestFunction();
+
+ // WebstoreInstallHelper::Delegate:
virtual void OnWebstoreParseSuccess(
const std::string& id,
const SkBitmap& icon,
@@ -113,12 +118,14 @@ class BeginInstallWithManifestFunction
InstallHelperResultCode result_code,
const std::string& error_message) OVERRIDE;
- // Implementing ExtensionInstallUI::Delegate interface.
+ // ExtensionInstallUI::Delegate:
virtual void InstallUIProceed() OVERRIDE;
virtual void InstallUIAbort(bool user_initiated) OVERRIDE;
protected:
virtual ~BeginInstallWithManifestFunction();
+
+ // ExtensionFunction:
virtual bool RunImpl() OVERRIDE;
// Sets the result_ as a string based on |code|.
@@ -142,22 +149,28 @@ class BeginInstallWithManifestFunction
// The class that displays the install prompt.
scoped_ptr<ExtensionInstallUI> install_ui_;
-
- DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.beginInstallWithManifest3");
};
class CompleteInstallFunction : public SyncExtensionFunction {
- virtual bool RunImpl() OVERRIDE;
+ public:
DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.completeInstall");
+
+ protected:
+ virtual ~CompleteInstallFunction() {}
+
+ // ExtensionFunction:
+ virtual bool RunImpl() OVERRIDE;
};
class SilentlyInstallFunction : public AsyncExtensionFunction,
public WebstoreInstallHelper::Delegate,
public WebstoreInstaller::Delegate {
public:
+ DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.silentlyInstall");
+
SilentlyInstallFunction();
- // WebstoreInstallHelper::Delegate implementation.
+ // WebstoreInstallHelper::Delegate:
virtual void OnWebstoreParseSuccess(
const std::string& id,
const SkBitmap& icon,
@@ -167,46 +180,69 @@ class SilentlyInstallFunction : public AsyncExtensionFunction,
InstallHelperResultCode result_code,
const std::string& error_message) OVERRIDE;
- // WebstoreInstaller::Delegate implementation.
+ // WebstoreInstaller::Delegate:
virtual void OnExtensionInstallSuccess(const std::string& id) OVERRIDE;
virtual void OnExtensionInstallFailure(const std::string& id,
const std::string& error) OVERRIDE;
protected:
virtual ~SilentlyInstallFunction();
+
+ // ExtensionFunction:
virtual bool RunImpl() OVERRIDE;
private:
std::string id_;
std::string manifest_;
- DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.silentlyInstall");
};
class GetBrowserLoginFunction : public SyncExtensionFunction {
- virtual bool RunImpl() OVERRIDE;
+ public:
DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.getBrowserLogin");
+
+ protected:
+ virtual ~GetBrowserLoginFunction() {}
+
+ // ExtensionFunction:
+ virtual bool RunImpl() OVERRIDE;
};
class GetStoreLoginFunction : public SyncExtensionFunction {
- virtual bool RunImpl() OVERRIDE;
+ public:
DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.getStoreLogin");
+
+ protected:
+ virtual ~GetStoreLoginFunction() {}
+
+ // ExtensionFunction:
+ virtual bool RunImpl() OVERRIDE;
};
class SetStoreLoginFunction : public SyncExtensionFunction {
- virtual bool RunImpl() OVERRIDE;
+ public:
DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.setStoreLogin");
+
+ protected:
+ virtual ~SetStoreLoginFunction() {}
+
+ // ExtensionFunction:
+ virtual bool RunImpl() OVERRIDE;
};
class GetWebGLStatusFunction : public AsyncExtensionFunction,
public content::GpuDataManagerObserver {
public:
+ DECLARE_EXTENSION_FUNCTION_NAME("webstorePrivate.getWebGLStatus");
+
GetWebGLStatusFunction();
- // Implementing GpuDataManagerObserver interface.
+ // content::GpuDataManagerObserver:
virtual void OnGpuInfoUpdate() OVERRIDE;
protected:
virtual ~GetWebGLStatusFunction();
+
+ // ExtensionFunction:
virtual bool RunImpl() OVERRIDE;
private:
@@ -215,8 +251,6 @@ class GetWebGLStatusFunction : public AsyncExtensionFunction,
// A false return value is always valid, but a true one is only valid if full
// GPU info has been collected in a GPU process.
static bool IsWebGLAllowed(content::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