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

Unified Diff: chrome/browser/content_settings/tab_specific_content_settings.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/content_settings/tab_specific_content_settings.cc
===================================================================
--- chrome/browser/content_settings/tab_specific_content_settings.cc (revision 91968)
+++ chrome/browser/content_settings/tab_specific_content_settings.cc (working copy)
@@ -17,6 +17,7 @@
#include "chrome/browser/content_settings/host_content_settings_map.h"
#include "chrome/browser/cookies_tree_model.h"
#include "chrome/browser/profiles/profile.h"
+#include "chrome/common/chrome_notification_types.h"
#include "chrome/common/render_messages.h"
#include "content/browser/renderer_host/render_process_host.h"
#include "content/browser/renderer_host/render_view_host.h"
@@ -54,7 +55,7 @@
ClearCookieSpecificContentSettings();
g_tab_specific.Get().push_back(this);
- registrar_.Add(this, NotificationType::CONTENT_SETTINGS_CHANGED,
+ registrar_.Add(this, chrome::NOTIFICATION_CONTENT_SETTINGS_CHANGED,
Source<HostContentSettingsMap>(
tab->profile()->GetHostContentSettingsMap()));
}
@@ -213,7 +214,7 @@
content_blocked_[type] = true;
// TODO: it would be nice to have a way of mocking this in tests.
NotificationService::current()->Notify(
- NotificationType::TAB_CONTENT_SETTINGS_CHANGED,
+ chrome::NOTIFICATION_TAB_CONTENT_SETTINGS_CHANGED,
Source<TabContents>(tab_contents()),
NotificationService::NoDetails());
}
@@ -225,7 +226,7 @@
if (!content_accessed_[type]) {
content_accessed_[type] = true;
NotificationService::current()->Notify(
- NotificationType::TAB_CONTENT_SETTINGS_CHANGED,
+ chrome::NOTIFICATION_TAB_CONTENT_SETTINGS_CHANGED,
Source<TabContents>(tab_contents()),
NotificationService::NoDetails());
}
@@ -351,7 +352,7 @@
geolocation_settings_state_.OnGeolocationPermissionSet(requesting_origin,
allowed);
NotificationService::current()->Notify(
- NotificationType::TAB_CONTENT_SETTINGS_CHANGED,
+ chrome::NOTIFICATION_TAB_CONTENT_SETTINGS_CHANGED,
Source<TabContents>(tab_contents()),
NotificationService::NoDetails());
}
@@ -367,7 +368,7 @@
}
load_plugins_link_enabled_ = true;
NotificationService::current()->Notify(
- NotificationType::TAB_CONTENT_SETTINGS_CHANGED,
+ chrome::NOTIFICATION_TAB_CONTENT_SETTINGS_CHANGED,
Source<TabContents>(tab_contents()),
NotificationService::NoDetails());
}
@@ -379,7 +380,7 @@
content_accessed_[CONTENT_SETTINGS_TYPE_COOKIES] = false;
content_blockage_indicated_to_user_[CONTENT_SETTINGS_TYPE_COOKIES] = false;
NotificationService::current()->Notify(
- NotificationType::TAB_CONTENT_SETTINGS_CHANGED,
+ chrome::NOTIFICATION_TAB_CONTENT_SETTINGS_CHANGED,
Source<TabContents>(tab_contents()),
NotificationService::NoDetails());
}
@@ -388,7 +389,7 @@
content_blocked_[CONTENT_SETTINGS_TYPE_POPUPS] = blocked;
content_blockage_indicated_to_user_[CONTENT_SETTINGS_TYPE_POPUPS] = false;
NotificationService::current()->Notify(
- NotificationType::TAB_CONTENT_SETTINGS_CHANGED,
+ chrome::NOTIFICATION_TAB_CONTENT_SETTINGS_CHANGED,
Source<TabContents>(tab_contents()),
NotificationService::NoDetails());
}
@@ -456,10 +457,10 @@
ClearGeolocationContentSettings();
}
-void TabSpecificContentSettings::Observe(NotificationType type,
+void TabSpecificContentSettings::Observe(int type,
const NotificationSource& source,
const NotificationDetails& details) {
- DCHECK(type.value == NotificationType::CONTENT_SETTINGS_CHANGED);
+ DCHECK(type == chrome::NOTIFICATION_CONTENT_SETTINGS_CHANGED);
Details<const ContentSettingsDetails> settings_details(details);
const NavigationController& controller = tab_contents()->controller();
« no previous file with comments | « chrome/browser/content_settings/tab_specific_content_settings.h ('k') | chrome/browser/cookies_tree_model_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698