| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/local_shared_objects_container.h" | 5 #include "chrome/browser/content_settings/local_shared_objects_container.h" |
| 6 | 6 |
| 7 #include "chrome/browser/browsing_data/browsing_data_appcache_helper.h" | 7 #include "chrome/browser/browsing_data/browsing_data_appcache_helper.h" |
| 8 #include "chrome/browser/browsing_data/browsing_data_cookie_helper.h" | 8 #include "chrome/browser/browsing_data/browsing_data_cookie_helper.h" |
| 9 #include "chrome/browser/browsing_data/browsing_data_database_helper.h" | 9 #include "chrome/browser/browsing_data/browsing_data_database_helper.h" |
| 10 #include "chrome/browser/browsing_data/browsing_data_file_system_helper.h" | 10 #include "chrome/browser/browsing_data/browsing_data_file_system_helper.h" |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 for (net::CookieList::const_iterator cookie = cookie_list->begin(); | 92 for (net::CookieList::const_iterator cookie = cookie_list->begin(); |
| 93 cookie != cookie_list->end(); | 93 cookie != cookie_list->end(); |
| 94 ++cookie) { | 94 ++cookie) { |
| 95 // Strip leading '.'s. | 95 // Strip leading '.'s. |
| 96 std::string cookie_domain = cookie->Domain(); | 96 std::string cookie_domain = cookie->Domain(); |
| 97 if (cookie_domain[0] == '.') | 97 if (cookie_domain[0] == '.') |
| 98 cookie_domain = cookie_domain.substr(1); | 98 cookie_domain = cookie_domain.substr(1); |
| 99 // The |domain_url| is only created in order to use the | 99 // The |domain_url| is only created in order to use the |
| 100 // SameDomainOrHost method below. It does not matter which scheme is | 100 // SameDomainOrHost method below. It does not matter which scheme is |
| 101 // used as the scheme is ignored by the SameDomainOrHost method. | 101 // used as the scheme is ignored by the SameDomainOrHost method. |
| 102 GURL domain_url(std::string(content::kHttpScheme) + | 102 GURL domain_url(std::string(url::kHttpScheme) + |
| 103 content::kStandardSchemeSeparator + cookie_domain); | 103 content::kStandardSchemeSeparator + cookie_domain); |
| 104 if (SameDomainOrHost(origin, domain_url)) | 104 if (SameDomainOrHost(origin, domain_url)) |
| 105 ++count; | 105 ++count; |
| 106 } | 106 } |
| 107 } | 107 } |
| 108 | 108 |
| 109 // Count local storages for the domain of the given |origin|. | 109 // Count local storages for the domain of the given |origin|. |
| 110 const std::set<GURL> local_storage_info = | 110 const std::set<GURL> local_storage_info = |
| 111 local_storages()->GetLocalStorageInfo(); | 111 local_storages()->GetLocalStorageInfo(); |
| 112 for (std::set<GURL>::const_iterator it = local_storage_info.begin(); | 112 for (std::set<GURL>::const_iterator it = local_storage_info.begin(); |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 session_storages(), | 190 session_storages(), |
| 191 appcaches(), | 191 appcaches(), |
| 192 indexed_dbs(), | 192 indexed_dbs(), |
| 193 file_systems(), | 193 file_systems(), |
| 194 NULL, | 194 NULL, |
| 195 server_bound_certs(), | 195 server_bound_certs(), |
| 196 NULL); | 196 NULL); |
| 197 | 197 |
| 198 return make_scoped_ptr(new CookiesTreeModel(container, NULL, true)); | 198 return make_scoped_ptr(new CookiesTreeModel(container, NULL, true)); |
| 199 } | 199 } |
| OLD | NEW |