OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/ui/webui/options/content_settings_handler.h" | 5 #include "chrome/browser/ui/webui/options/content_settings_handler.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/callback.h" | 11 #include "base/callback.h" |
12 #include "base/command_line.h" | 12 #include "base/command_line.h" |
13 #include "base/utf_string_conversions.h" | 13 #include "base/utf_string_conversions.h" |
14 #include "base/values.h" | 14 #include "base/values.h" |
15 #include "chrome/browser/browser_process.h" | 15 #include "chrome/browser/browser_process.h" |
16 #include "chrome/browser/content_settings/content_settings_details.h" | 16 #include "chrome/browser/content_settings/content_settings_details.h" |
17 #include "chrome/browser/content_settings/content_settings_pattern.h" | |
18 #include "chrome/browser/content_settings/content_settings_utils.h" | 17 #include "chrome/browser/content_settings/content_settings_utils.h" |
19 #include "chrome/browser/content_settings/host_content_settings_map.h" | 18 #include "chrome/browser/content_settings/host_content_settings_map.h" |
20 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" | 19 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" |
21 #include "chrome/browser/notifications/desktop_notification_service.h" | 20 #include "chrome/browser/notifications/desktop_notification_service.h" |
22 #include "chrome/browser/notifications/desktop_notification_service_factory.h" | 21 #include "chrome/browser/notifications/desktop_notification_service_factory.h" |
23 #include "chrome/browser/profiles/profile.h" | 22 #include "chrome/browser/profiles/profile.h" |
24 #include "chrome/browser/ui/browser_list.h" | 23 #include "chrome/browser/ui/browser_list.h" |
25 #include "chrome/common/chrome_notification_types.h" | 24 #include "chrome/common/chrome_notification_types.h" |
26 #include "chrome/common/chrome_switches.h" | 25 #include "chrome/common/chrome_switches.h" |
| 26 #include "chrome/common/content_settings_pattern.h" |
27 #include "chrome/common/pref_names.h" | 27 #include "chrome/common/pref_names.h" |
28 #include "chrome/common/url_constants.h" | 28 #include "chrome/common/url_constants.h" |
29 #include "content/browser/tab_contents/tab_contents.h" | 29 #include "content/browser/tab_contents/tab_contents.h" |
30 #include "content/common/content_notification_types.h" | 30 #include "content/common/content_notification_types.h" |
31 #include "content/common/content_switches.h" | 31 #include "content/common/content_switches.h" |
32 #include "content/common/notification_service.h" | 32 #include "content/common/notification_service.h" |
33 #include "content/common/notification_source.h" | 33 #include "content/common/notification_source.h" |
34 #include "grit/generated_resources.h" | 34 #include "grit/generated_resources.h" |
35 #include "grit/locale_settings.h" | 35 #include "grit/locale_settings.h" |
36 #include "ui/base/l10n/l10n_util.h" | 36 #include "ui/base/l10n/l10n_util.h" |
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
767 return Profile::FromWebUI(web_ui_)->GetProtocolHandlerRegistry(); | 767 return Profile::FromWebUI(web_ui_)->GetProtocolHandlerRegistry(); |
768 } | 768 } |
769 | 769 |
770 HostContentSettingsMap* | 770 HostContentSettingsMap* |
771 ContentSettingsHandler::GetOTRContentSettingsMap() { | 771 ContentSettingsHandler::GetOTRContentSettingsMap() { |
772 Profile* profile = Profile::FromWebUI(web_ui_); | 772 Profile* profile = Profile::FromWebUI(web_ui_); |
773 if (profile->HasOffTheRecordProfile()) | 773 if (profile->HasOffTheRecordProfile()) |
774 return profile->GetOffTheRecordProfile()->GetHostContentSettingsMap(); | 774 return profile->GetOffTheRecordProfile()->GetHostContentSettingsMap(); |
775 return NULL; | 775 return NULL; |
776 } | 776 } |
OLD | NEW |