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

Unified Diff: chrome/browser/extensions/extension_infobar_delegate.cc

Issue 7327007: Moving notification types which are chrome specific to a new header file chrome_notification_type... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 5 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_infobar_delegate.cc
===================================================================
--- chrome/browser/extensions/extension_infobar_delegate.cc (revision 91968)
+++ chrome/browser/extensions/extension_infobar_delegate.cc (working copy)
@@ -9,10 +9,10 @@
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h"
+#include "chrome/common/chrome_notification_types.h"
#include "chrome/common/extensions/extension.h"
#include "content/common/notification_details.h"
#include "content/common/notification_source.h"
-#include "content/common/notification_type.h"
ExtensionInfoBarDelegate::ExtensionInfoBarDelegate(Browser* browser,
TabContents* tab_contents,
@@ -28,9 +28,9 @@
extension_host_.reset(manager->CreateInfobarHost(url, browser));
extension_host_->set_associated_tab_contents(tab_contents);
- registrar_.Add(this, NotificationType::EXTENSION_HOST_VIEW_SHOULD_CLOSE,
+ registrar_.Add(this, chrome::NOTIFICATION_EXTENSION_HOST_VIEW_SHOULD_CLOSE,
Source<Profile>(browser->profile()));
- registrar_.Add(this, NotificationType::EXTENSION_UNLOADED,
+ registrar_.Add(this, chrome::NOTIFICATION_EXTENSION_UNLOADED,
Source<Profile>(browser->profile()));
}
@@ -68,19 +68,19 @@
return this;
}
-void ExtensionInfoBarDelegate::Observe(NotificationType type,
+void ExtensionInfoBarDelegate::Observe(int type,
const NotificationSource& source,
const NotificationDetails& details) {
TabContentsWrapper* wrapper =
TabContentsWrapper::GetCurrentWrapperForContents(tab_contents_);
- switch (type.value) {
- case NotificationType::EXTENSION_HOST_VIEW_SHOULD_CLOSE: {
+ switch (type) {
+ case chrome::NOTIFICATION_EXTENSION_HOST_VIEW_SHOULD_CLOSE: {
const ExtensionHost* result = Details<ExtensionHost>(details).ptr();
if (extension_host_.get() == result)
wrapper->RemoveInfoBar(this);
break;
}
- case NotificationType::EXTENSION_UNLOADED: {
+ case chrome::NOTIFICATION_EXTENSION_UNLOADED: {
const Extension* extension =
Details<UnloadedExtensionInfo>(details)->extension;
if (extension_ == extension)
« no previous file with comments | « chrome/browser/extensions/extension_infobar_delegate.h ('k') | chrome/browser/extensions/extension_input_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698