| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_CONTROLLER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include "chrome/browser/extensions/extension_message_bubble.h" | 9 #include "chrome/browser/extensions/extension_message_bubble.h" |
| 10 #include "extensions/browser/browser_context_keyed_api_factory.h" | 10 #include "extensions/browser/browser_context_keyed_api_factory.h" |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 virtual base::string16 GetOverflowText( | 46 virtual base::string16 GetOverflowText( |
| 47 const base::string16& overflow_count) const = 0; | 47 const base::string16& overflow_count) const = 0; |
| 48 virtual base::string16 GetLearnMoreLabel() const = 0; | 48 virtual base::string16 GetLearnMoreLabel() const = 0; |
| 49 virtual GURL GetLearnMoreUrl() const = 0; | 49 virtual GURL GetLearnMoreUrl() const = 0; |
| 50 virtual base::string16 GetActionButtonLabel() const = 0; | 50 virtual base::string16 GetActionButtonLabel() const = 0; |
| 51 virtual base::string16 GetDismissButtonLabel() const = 0; | 51 virtual base::string16 GetDismissButtonLabel() const = 0; |
| 52 | 52 |
| 53 // Whether to show a list of extensions in the bubble. | 53 // Whether to show a list of extensions in the bubble. |
| 54 virtual bool ShouldShowExtensionList() const = 0; | 54 virtual bool ShouldShowExtensionList() const = 0; |
| 55 | 55 |
| 56 // In some cases, we want the delegate only to handle a single extension |
| 57 // and this sets which extension. |
| 58 virtual void RestrictToSingleExtension(const std::string& extension_id); |
| 59 |
| 56 // Record, through UMA, how many extensions were found. | 60 // Record, through UMA, how many extensions were found. |
| 57 virtual void LogExtensionCount(size_t count) = 0; | 61 virtual void LogExtensionCount(size_t count) = 0; |
| 58 virtual void LogAction(BubbleAction action) = 0; | 62 virtual void LogAction(BubbleAction action) = 0; |
| 59 }; | 63 }; |
| 60 | 64 |
| 61 ExtensionMessageBubbleController(Delegate* delegate, Profile* profile); | 65 ExtensionMessageBubbleController(Delegate* delegate, Profile* profile); |
| 62 virtual ~ExtensionMessageBubbleController(); | 66 virtual ~ExtensionMessageBubbleController(); |
| 63 | 67 |
| 64 Delegate* delegate() const { return delegate_.get(); } | 68 Delegate* delegate() const { return delegate_.get(); } |
| 65 | 69 |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 | 105 |
| 102 // Whether this class has initialized. | 106 // Whether this class has initialized. |
| 103 bool initialized_; | 107 bool initialized_; |
| 104 | 108 |
| 105 DISALLOW_COPY_AND_ASSIGN(ExtensionMessageBubbleController); | 109 DISALLOW_COPY_AND_ASSIGN(ExtensionMessageBubbleController); |
| 106 }; | 110 }; |
| 107 | 111 |
| 108 } // namespace extensions | 112 } // namespace extensions |
| 109 | 113 |
| 110 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_CONTROLLER_H_ | 114 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_CONTROLLER_H_ |
| OLD | NEW |