| Index: chrome/browser/extensions/suspicious_extension_bubble_controller.h
|
| diff --git a/chrome/browser/extensions/suspicious_extension_bubble_controller.h b/chrome/browser/extensions/suspicious_extension_bubble_controller.h
|
| index 0618135f53e7cf237f7df3a589c8d0d079a15b93..1e71d9a00ff121a172059c5ff62a5dfc3104fc43 100644
|
| --- a/chrome/browser/extensions/suspicious_extension_bubble_controller.h
|
| +++ b/chrome/browser/extensions/suspicious_extension_bubble_controller.h
|
| @@ -7,6 +7,7 @@
|
|
|
| #include <string>
|
| #include "chrome/browser/extensions/api/profile_keyed_api_factory.h"
|
| +#include "chrome/browser/extensions/extension_message_bubble_controller.h"
|
| #include "extensions/common/extension.h"
|
|
|
| class Browser;
|
| @@ -16,7 +17,9 @@ namespace extensions {
|
|
|
| class SuspiciousExtensionBubble;
|
|
|
| -class SuspiciousExtensionBubbleController : public ProfileKeyedAPI {
|
| +class SuspiciousExtensionBubbleController
|
| + : public ProfileKeyedAPI,
|
| + public ExtensionMessageBubbleController {
|
| public:
|
| explicit SuspiciousExtensionBubbleController(Profile* profile);
|
| virtual ~SuspiciousExtensionBubbleController();
|
| @@ -29,26 +32,6 @@ class SuspiciousExtensionBubbleController : public ProfileKeyedAPI {
|
| // profile.
|
| static SuspiciousExtensionBubbleController* Get(Profile* profile);
|
|
|
| - // Check for suspicious extensions, returns true if found.
|
| - bool HasSuspiciousExtensions();
|
| -
|
| - // Sets up the callbacks and shows the bubble.
|
| - void Show(SuspiciousExtensionBubble* bubble);
|
| -
|
| - // Text for various UI labels shown in the bubble.
|
| - string16 GetTitle();
|
| - string16 GetMessageBody();
|
| - string16 GetOverflowText(const string16& overflow_count);
|
| - string16 GetLearnMoreLabel();
|
| - string16 GetDismissButtonLabel();
|
| -
|
| - // Returns a vector of names of suspicious extensions found.
|
| - std::vector<string16> GetSuspiciousExtensionNames();
|
| -
|
| - // Callbacks from bubble. Declared virtual for testing purposes.
|
| - virtual void OnBubbleDismiss();
|
| - virtual void OnLinkClicked();
|
| -
|
| private:
|
| friend class ProfileKeyedAPIFactory<SuspiciousExtensionBubbleController>;
|
|
|
| @@ -58,23 +41,10 @@ class SuspiciousExtensionBubbleController : public ProfileKeyedAPI {
|
| }
|
| static const bool kServiceRedirectedInIncognito = true;
|
|
|
| - // Mark all extensions found as acknowledged (don't need to warn about them
|
| - // again).
|
| - void AcknowledgeWipeout();
|
| -
|
| - // The list of suspicious extensions found. Reset at the beginning of each
|
| - // call to FoundSuspiciousExtensions.
|
| - ExtensionIdList suspicious_extensions_;
|
| -
|
| - // Our extension service. Weak, not owned by us.
|
| - ExtensionService* service_;
|
| -
|
| - // A weak pointer to the profile we are associated with. Not owned by us.
|
| - Profile* profile_;
|
| -
|
| - // This object only checks once for suspicious extensions because the dataset
|
| - // doesn't change after startup.
|
| - bool has_notified_;
|
| + // ExtensionMessageBubbleController methods.
|
| + virtual bool ShouldIncludeExtension(const std::string& extension_id) OVERRIDE;
|
| + virtual void AcknowledgeExtension(const std::string& extension_id) OVERRIDE;
|
| + virtual void PerformAction() OVERRIDE;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(SuspiciousExtensionBubbleController);
|
| };
|
|
|