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

Unified Diff: chrome/browser/extensions/api/push_messaging/push_messaging_api.h

Issue 666153002: Standardize usage of virtual/override/final in chrome/browser/extensions/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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/api/push_messaging/push_messaging_api.h
diff --git a/chrome/browser/extensions/api/push_messaging/push_messaging_api.h b/chrome/browser/extensions/api/push_messaging/push_messaging_api.h
index 4da36f753e8e15976dfab9ae1d1ba51d89ca10d5..854475c7b4126a1a82fc59119fbeb223829fbe32 100644
--- a/chrome/browser/extensions/api/push_messaging/push_messaging_api.h
+++ b/chrome/browser/extensions/api/push_messaging/push_messaging_api.h
@@ -34,7 +34,7 @@ class PushMessagingEventRouter
: public PushMessagingInvalidationHandlerDelegate {
public:
explicit PushMessagingEventRouter(content::BrowserContext* context);
- virtual ~PushMessagingEventRouter();
+ ~PushMessagingEventRouter() override;
// For testing purposes.
void TriggerMessageForTest(const std::string& extension_id,
@@ -43,9 +43,9 @@ class PushMessagingEventRouter
private:
// InvalidationHandlerDelegate implementation.
- virtual void OnMessage(const std::string& extension_id,
- int subchannel,
- const std::string& payload) override;
+ void OnMessage(const std::string& extension_id,
+ int subchannel,
+ const std::string& payload) override;
content::BrowserContext* const browser_context_;
@@ -61,10 +61,10 @@ class PushMessagingGetChannelIdFunction
PushMessagingGetChannelIdFunction();
protected:
- virtual ~PushMessagingGetChannelIdFunction();
+ ~PushMessagingGetChannelIdFunction() override;
// ExtensionFunction:
- virtual bool RunAsync() override;
+ bool RunAsync() override;
DECLARE_EXTENSION_FUNCTION("pushMessaging.getChannelId",
PUSHMESSAGING_GETCHANNELID)
@@ -82,21 +82,18 @@ class PushMessagingGetChannelIdFunction
void StartAccessTokenFetch();
// OAuth2TokenService::Observer implementation.
- virtual void OnRefreshTokenAvailable(const std::string& account_id) override;
+ void OnRefreshTokenAvailable(const std::string& account_id) override;
// OAuth2TokenService::Consumer implementation.
- virtual void OnGetTokenSuccess(
- const OAuth2TokenService::Request* request,
- const std::string& access_token,
- const base::Time& expiration_time) override;
- virtual void OnGetTokenFailure(
- const OAuth2TokenService::Request* request,
- const GoogleServiceAuthError& error) override;
+ void OnGetTokenSuccess(const OAuth2TokenService::Request* request,
+ const std::string& access_token,
+ const base::Time& expiration_time) override;
+ void OnGetTokenFailure(const OAuth2TokenService::Request* request,
+ const GoogleServiceAuthError& error) override;
// ObfuscatedGiaiaIdFetcher::Delegate implementation.
- virtual void OnObfuscatedGaiaIdFetchSuccess(const std::string& gaia_id)
- override;
- virtual void OnObfuscatedGaiaIdFetchFailure(
+ void OnObfuscatedGaiaIdFetchSuccess(const std::string& gaia_id) override;
+ void OnObfuscatedGaiaIdFetchFailure(
const GoogleServiceAuthError& error) override;
scoped_ptr<ObfuscatedGaiaIdFetcher> fetcher_;
@@ -110,13 +107,13 @@ class PushMessagingAPI : public BrowserContextKeyedAPI,
public ExtensionRegistryObserver {
public:
explicit PushMessagingAPI(content::BrowserContext* context);
- virtual ~PushMessagingAPI();
+ ~PushMessagingAPI() override;
// Convenience method to get the PushMessagingAPI for a BrowserContext.
static PushMessagingAPI* Get(content::BrowserContext* context);
// KeyedService implementation.
- virtual void Shutdown() override;
+ void Shutdown() override;
// BrowserContextKeyedAPI implementation.
static BrowserContextKeyedAPIFactory<PushMessagingAPI>* GetFactoryInstance();
@@ -140,18 +137,16 @@ class PushMessagingAPI : public BrowserContextKeyedAPI,
static const bool kServiceIsNULLWhileTesting = true;
// Overridden from ExtensionRegistryObserver.
- virtual void OnExtensionLoaded(content::BrowserContext* browser_context,
- const Extension* extension) override;
- virtual void OnExtensionUnloaded(
- content::BrowserContext* browser_context,
- const Extension* extension,
- UnloadedExtensionInfo::Reason reason) override;
- virtual void OnExtensionWillBeInstalled(
- content::BrowserContext* browser_context,
- const Extension* extension,
- bool is_update,
- bool from_ephemeral,
- const std::string& old_name) override;
+ void OnExtensionLoaded(content::BrowserContext* browser_context,
+ const Extension* extension) override;
+ void OnExtensionUnloaded(content::BrowserContext* browser_context,
+ const Extension* extension,
+ UnloadedExtensionInfo::Reason reason) override;
+ void OnExtensionWillBeInstalled(content::BrowserContext* browser_context,
+ const Extension* extension,
+ bool is_update,
+ bool from_ephemeral,
+ const std::string& old_name) override;
// Initialize |event_router_| and |handler_|.
bool InitEventRouterAndHandler();

Powered by Google App Engine
This is Rietveld 408576698