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

Side by Side Diff: chrome/browser/notifications/desktop_notification_profile_util.cc

Issue 579673003: Move content_settings_observer.h, content_settings_provider.h, content_settings_rule.* to the compo… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: last comment Created 6 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "chrome/browser/notifications/desktop_notification_profile_util.h" 5 #include "chrome/browser/notifications/desktop_notification_profile_util.h"
6 6
7 #include "chrome/browser/content_settings/content_settings_provider.h"
8 #include "chrome/browser/content_settings/host_content_settings_map.h" 7 #include "chrome/browser/content_settings/host_content_settings_map.h"
9 #include "chrome/browser/profiles/profile.h" 8 #include "chrome/browser/profiles/profile.h"
9 #include "components/content_settings/core/browser/content_settings_provider.h"
10 #include "components/content_settings/core/common/content_settings_pattern.h" 10 #include "components/content_settings/core/common/content_settings_pattern.h"
11 11
12 void DesktopNotificationProfileUtil::ResetToDefaultContentSetting( 12 void DesktopNotificationProfileUtil::ResetToDefaultContentSetting(
13 Profile* profile) { 13 Profile* profile) {
14 profile->GetHostContentSettingsMap()->SetDefaultContentSetting( 14 profile->GetHostContentSettingsMap()->SetDefaultContentSetting(
15 CONTENT_SETTINGS_TYPE_NOTIFICATIONS, CONTENT_SETTING_DEFAULT); 15 CONTENT_SETTINGS_TYPE_NOTIFICATIONS, CONTENT_SETTING_DEFAULT);
16 } 16 }
17 17
18 // Clears the notifications setting for the given pattern. 18 // Clears the notifications setting for the given pattern.
19 void DesktopNotificationProfileUtil::ClearSetting( 19 void DesktopNotificationProfileUtil::ClearSetting(
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 NO_RESOURCE_IDENTIFIER); 69 NO_RESOURCE_IDENTIFIER);
70 } 70 }
71 71
72 void DesktopNotificationProfileUtil::UsePermission(Profile* profile, 72 void DesktopNotificationProfileUtil::UsePermission(Profile* profile,
73 const GURL& origin) { 73 const GURL& origin) {
74 profile->GetHostContentSettingsMap()->UpdateLastUsageByPattern( 74 profile->GetHostContentSettingsMap()->UpdateLastUsageByPattern(
75 ContentSettingsPattern::FromURLNoWildcard(origin), 75 ContentSettingsPattern::FromURLNoWildcard(origin),
76 ContentSettingsPattern::Wildcard(), 76 ContentSettingsPattern::Wildcard(),
77 CONTENT_SETTINGS_TYPE_NOTIFICATIONS); 77 CONTENT_SETTINGS_TYPE_NOTIFICATIONS);
78 } 78 }
OLDNEW
« no previous file with comments | « chrome/browser/media/media_stream_devices_controller.cc ('k') | chrome/browser/notifications/desktop_notification_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698