| 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/content_settings/host_content_settings_map.h" | 5 #include "chrome/browser/content_settings/host_content_settings_map.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| 11 #include "base/stl_util.h" | 11 #include "base/stl_util.h" |
| 12 #include "base/string_util.h" | 12 #include "base/string_util.h" |
| 13 #include "base/utf_string_conversions.h" | 13 #include "base/utf_string_conversions.h" |
| 14 #include "chrome/browser/content_settings/content_settings_default_provider.h" | 14 #include "chrome/browser/content_settings/content_settings_default_provider.h" |
| 15 #include "chrome/browser/content_settings/content_settings_details.h" | 15 #include "chrome/browser/content_settings/content_settings_details.h" |
| 16 #include "chrome/browser/content_settings/content_settings_extension_provider.h" | 16 #include "chrome/browser/content_settings/content_settings_extension_provider.h" |
| 17 #include "chrome/browser/content_settings/content_settings_observable_provider.h
" | 17 #include "chrome/browser/content_settings/content_settings_observable_provider.h
" |
| 18 #include "chrome/browser/content_settings/content_settings_policy_provider.h" | 18 #include "chrome/browser/content_settings/content_settings_policy_provider.h" |
| 19 #include "chrome/browser/content_settings/content_settings_pref_provider.h" | 19 #include "chrome/browser/content_settings/content_settings_pref_provider.h" |
| 20 #include "chrome/browser/content_settings/content_settings_provider.h" | 20 #include "chrome/browser/content_settings/content_settings_provider.h" |
| 21 #include "chrome/browser/content_settings/content_settings_rule.h" | 21 #include "chrome/browser/content_settings/content_settings_rule.h" |
| 22 #include "chrome/browser/content_settings/content_settings_utils.h" | 22 #include "chrome/browser/content_settings/content_settings_utils.h" |
| 23 #include "chrome/browser/extensions/extension_service.h" | 23 #include "chrome/browser/extensions/extension_service.h" |
| 24 #include "chrome/browser/prefs/pref_service.h" | 24 #include "chrome/browser/prefs/pref_service.h" |
| 25 #include "chrome/common/chrome_notification_types.h" | 25 #include "chrome/common/chrome_notification_types.h" |
| 26 #include "chrome/common/chrome_switches.h" | 26 #include "chrome/common/chrome_switches.h" |
| 27 #include "chrome/common/content_settings_pattern.h" | 27 #include "chrome/common/content_settings_pattern.h" |
| 28 #include "chrome/common/pref_names.h" | 28 #include "chrome/common/pref_names.h" |
| 29 #include "chrome/common/url_constants.h" | 29 #include "chrome/common/url_constants.h" |
| 30 #include "content/browser/user_metrics.h" | |
| 31 #include "content/public/browser/browser_thread.h" | 30 #include "content/public/browser/browser_thread.h" |
| 32 #include "content/public/browser/notification_service.h" | 31 #include "content/public/browser/notification_service.h" |
| 33 #include "content/public/browser/notification_source.h" | 32 #include "content/public/browser/notification_source.h" |
| 33 #include "content/public/browser/user_metrics.h" |
| 34 #include "content/public/common/content_switches.h" | 34 #include "content/public/common/content_switches.h" |
| 35 #include "googleurl/src/gurl.h" | 35 #include "googleurl/src/gurl.h" |
| 36 #include "net/base/net_errors.h" | 36 #include "net/base/net_errors.h" |
| 37 #include "net/base/static_cookie_policy.h" | 37 #include "net/base/static_cookie_policy.h" |
| 38 | 38 |
| 39 using content::BrowserThread; | 39 using content::BrowserThread; |
| 40 using content::UserMetricsAction; |
| 40 | 41 |
| 41 namespace { | 42 namespace { |
| 42 | 43 |
| 43 typedef std::vector<content_settings::Rule> Rules; | 44 typedef std::vector<content_settings::Rule> Rules; |
| 44 | 45 |
| 45 typedef std::pair<std::string, std::string> StringPair; | 46 typedef std::pair<std::string, std::string> StringPair; |
| 46 | 47 |
| 47 const char* kProviderNames[] = { | 48 const char* kProviderNames[] = { |
| 48 "policy", | 49 "policy", |
| 49 "extension", | 50 "extension", |
| (...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 455 } | 456 } |
| 456 } | 457 } |
| 457 | 458 |
| 458 if (info) { | 459 if (info) { |
| 459 info->source = content_settings::SETTING_SOURCE_NONE; | 460 info->source = content_settings::SETTING_SOURCE_NONE; |
| 460 info->primary_pattern = ContentSettingsPattern(); | 461 info->primary_pattern = ContentSettingsPattern(); |
| 461 info->secondary_pattern = ContentSettingsPattern(); | 462 info->secondary_pattern = ContentSettingsPattern(); |
| 462 } | 463 } |
| 463 return NULL; | 464 return NULL; |
| 464 } | 465 } |
| OLD | NEW |