summaryrefslogtreecommitdiffstats
path: root/chrome/browser/extensions/extension_message_bubble.h
diff options
context:
space:
mode:
authorfinnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-13 21:57:53 +0000
committerfinnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-13 21:57:53 +0000
commitc72ebfe8fb90b1109ce82291d84d2311b6d664e1 (patch)
tree913463659528bdae35253dc4952e159fbb8ae0f1 /chrome/browser/extensions/extension_message_bubble.h
parent64eb411b1fd5ad9e431410dda23a9144876db534 (diff)
downloadchromium_src-c72ebfe8fb90b1109ce82291d84d2311b6d664e1.zip
chromium_src-c72ebfe8fb90b1109ce82291d84d2311b6d664e1.tar.gz
chromium_src-c72ebfe8fb90b1109ce82291d84d2311b6d664e1.tar.bz2
Add an extension bubble explaining which extensions are in dev mode.
Note: This is a brand new changelist (the other one got corrupt somehow). Review happened here: https://codereview.chromium.org/95133002/ In order to accomplish this without too much code duplication I refactored the common code of the newly added SuspiciousExtension bubble into a base class ExtensionMessageBubbleController and a derived class (SuspiciousExtensionBubbleController) to accomodate a new type of bubble (DevModeBubbleController). I also generalized the BubbleView code to just display whatever the controller tells it (and removed mentions of SuspiciousExtensions from it). The new controller has an action button (Disable) so new functionality was added to accomodate. BUG=328441 Review URL: https://codereview.chromium.org/114153003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240767 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_message_bubble.h')
-rw-r--r--chrome/browser/extensions/extension_message_bubble.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/chrome/browser/extensions/extension_message_bubble.h b/chrome/browser/extensions/extension_message_bubble.h
new file mode 100644
index 0000000..bdce711
--- /dev/null
+++ b/chrome/browser/extensions/extension_message_bubble.h
@@ -0,0 +1,34 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_H_
+#define CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_H_
+
+#include "base/bind.h"
+
+class Browser;
+
+namespace extensions {
+
+// The interface between the SuspiciousExtensionBubble bubble and its
+// controller.
+class ExtensionMessageBubble {
+ public:
+ // Setup the callback for when the action button is clicked in the
+ // bubble.
+ virtual void OnActionButtonClicked(const base::Closure& callback) = 0;
+
+ // Setup the callback for when the dismiss button is clicked.
+ virtual void OnDismissButtonClicked(const base::Closure& callback) = 0;
+
+ // Setup the callback for when the link is clicked in the bubble.
+ virtual void OnLinkClicked(const base::Closure& callback) = 0;
+
+ // Instruct the bubble to appear.
+ virtual void Show() = 0;
+};
+
+} // namespace extensions
+
+#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_BUBBLE_H_