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

Unified Diff: chrome/browser/tabs/tab_strip_model.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
« no previous file with comments | « chrome/browser/tabs/tab_strip_model.h ('k') | chrome/browser/tabs/tab_strip_model_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/tabs/tab_strip_model.cc
===================================================================
--- chrome/browser/tabs/tab_strip_model.cc (revision 91968)
+++ chrome/browser/tabs/tab_strip_model.cc (working copy)
@@ -22,6 +22,7 @@
#include "chrome/browser/tabs/tab_strip_model_delegate.h"
#include "chrome/browser/tabs/tab_strip_model_order_controller.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 "chrome/common/url_constants.h"
#include "content/browser/renderer_host/render_process_host.h"
@@ -66,10 +67,10 @@
order_controller_(NULL) {
DCHECK(delegate_);
registrar_.Add(this,
- NotificationType::TAB_CONTENTS_DESTROYED,
+ content::NOTIFICATION_TAB_CONTENTS_DESTROYED,
NotificationService::AllSources());
registrar_.Add(this,
- NotificationType::EXTENSION_UNLOADED,
+ chrome::NOTIFICATION_EXTENSION_UNLOADED,
Source<Profile>(profile_));
order_controller_ = new TabStripModelOrderController(this);
}
@@ -987,11 +988,11 @@
///////////////////////////////////////////////////////////////////////////////
// TabStripModel, NotificationObserver implementation:
-void TabStripModel::Observe(NotificationType type,
+void TabStripModel::Observe(int type,
const NotificationSource& source,
const NotificationDetails& details) {
- switch (type.value) {
- case NotificationType::TAB_CONTENTS_DESTROYED: {
+ switch (type) {
+ case content::NOTIFICATION_TAB_CONTENTS_DESTROYED: {
// Sometimes, on qemu, it seems like a TabContents object can be destroyed
// while we still have a reference to it. We need to break this reference
// here so we don't crash later.
@@ -1004,7 +1005,7 @@
break;
}
- case NotificationType::EXTENSION_UNLOADED: {
+ case chrome::NOTIFICATION_EXTENSION_UNLOADED: {
const Extension* extension =
Details<UnloadedExtensionInfo>(details)->extension;
// Iterate backwards as we may remove items while iterating.
« no previous file with comments | « chrome/browser/tabs/tab_strip_model.h ('k') | chrome/browser/tabs/tab_strip_model_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698