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

Side by Side Diff: chrome/browser/browsing_data/cookies_tree_model.cc

Issue 102103005: Move c/c/e/extension_set to top-level extensions/ (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 7 years 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 (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/browsing_data/cookies_tree_model.h" 5 #include "chrome/browser/browsing_data/cookies_tree_model.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <functional> 8 #include <functional>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/bind.h" 11 #include "base/bind.h"
12 #include "base/memory/linked_ptr.h" 12 #include "base/memory/linked_ptr.h"
13 #include "base/strings/string_util.h" 13 #include "base/strings/string_util.h"
14 #include "base/strings/utf_string_conversions.h" 14 #include "base/strings/utf_string_conversions.h"
15 #include "chrome/browser/browsing_data/browsing_data_cookie_helper.h" 15 #include "chrome/browser/browsing_data/browsing_data_cookie_helper.h"
16 #include "chrome/browser/browsing_data/browsing_data_flash_lso_helper.h" 16 #include "chrome/browser/browsing_data/browsing_data_flash_lso_helper.h"
17 #include "chrome/browser/browsing_data/browsing_data_server_bound_cert_helper.h" 17 #include "chrome/browser/browsing_data/browsing_data_server_bound_cert_helper.h"
18 #include "chrome/browser/content_settings/cookie_settings.h" 18 #include "chrome/browser/content_settings/cookie_settings.h"
19 #include "chrome/browser/extensions/extension_service.h" 19 #include "chrome/browser/extensions/extension_service.h"
20 #include "chrome/browser/extensions/extension_special_storage_policy.h" 20 #include "chrome/browser/extensions/extension_special_storage_policy.h"
21 #include "content/public/common/url_constants.h" 21 #include "content/public/common/url_constants.h"
22 #include "extensions/common/extension_set.h"
22 #include "grit/generated_resources.h" 23 #include "grit/generated_resources.h"
23 #include "grit/theme_resources.h" 24 #include "grit/theme_resources.h"
24 #include "grit/ui_resources.h" 25 #include "grit/ui_resources.h"
25 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" 26 #include "net/base/registry_controlled_domains/registry_controlled_domain.h"
26 #include "net/cookies/canonical_cookie.h" 27 #include "net/cookies/canonical_cookie.h"
27 #include "net/url_request/url_request_context.h" 28 #include "net/url_request/url_request_context.h"
28 #include "ui/base/l10n/l10n_util.h" 29 #include "ui/base/l10n/l10n_util.h"
29 #include "ui/base/resource/resource_bundle.h" 30 #include "ui/base/resource/resource_bundle.h"
30 #include "ui/gfx/image/image_skia.h" 31 #include "ui/gfx/image/image_skia.h"
31 32
(...skipping 917 matching lines...) Expand 10 before | Expand all | Expand 10 after
949 PopulateDatabaseInfoWithFilter(data_container(), &notifier, filter); 950 PopulateDatabaseInfoWithFilter(data_container(), &notifier, filter);
950 PopulateLocalStorageInfoWithFilter(data_container(), &notifier, filter); 951 PopulateLocalStorageInfoWithFilter(data_container(), &notifier, filter);
951 PopulateSessionStorageInfoWithFilter(data_container(), &notifier, filter); 952 PopulateSessionStorageInfoWithFilter(data_container(), &notifier, filter);
952 PopulateAppCacheInfoWithFilter(data_container(), &notifier, filter); 953 PopulateAppCacheInfoWithFilter(data_container(), &notifier, filter);
953 PopulateIndexedDBInfoWithFilter(data_container(), &notifier, filter); 954 PopulateIndexedDBInfoWithFilter(data_container(), &notifier, filter);
954 PopulateFileSystemInfoWithFilter(data_container(), &notifier, filter); 955 PopulateFileSystemInfoWithFilter(data_container(), &notifier, filter);
955 PopulateQuotaInfoWithFilter(data_container(), &notifier, filter); 956 PopulateQuotaInfoWithFilter(data_container(), &notifier, filter);
956 PopulateServerBoundCertInfoWithFilter(data_container(), &notifier, filter); 957 PopulateServerBoundCertInfoWithFilter(data_container(), &notifier, filter);
957 } 958 }
958 959
959 const ExtensionSet* CookiesTreeModel::ExtensionsProtectingNode( 960 const extensions::ExtensionSet* CookiesTreeModel::ExtensionsProtectingNode(
960 const CookieTreeNode& cookie_node) { 961 const CookieTreeNode& cookie_node) {
961 if (!special_storage_policy_.get()) 962 if (!special_storage_policy_.get())
962 return NULL; 963 return NULL;
963 964
964 CookieTreeNode::DetailedInfo info = cookie_node.GetDetailedInfo(); 965 CookieTreeNode::DetailedInfo info = cookie_node.GetDetailedInfo();
965 966
966 if (!TypeIsProtected(info.node_type)) 967 if (!TypeIsProtected(info.node_type))
967 return NULL; 968 return NULL;
968 969
969 DCHECK(!info.origin.is_empty()); 970 DCHECK(!info.origin.is_empty());
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after
1327 1328
1328 void CookiesTreeModel::NotifyObserverEndBatch() { 1329 void CookiesTreeModel::NotifyObserverEndBatch() {
1329 // Only notify the observers if this is the outermost call to EndBatch() if 1330 // Only notify the observers if this is the outermost call to EndBatch() if
1330 // called in a nested manner. 1331 // called in a nested manner.
1331 if (--batch_update_ == 0) { 1332 if (--batch_update_ == 0) {
1332 FOR_EACH_OBSERVER(Observer, 1333 FOR_EACH_OBSERVER(Observer,
1333 cookies_observer_list_, 1334 cookies_observer_list_,
1334 TreeModelEndBatch(this)); 1335 TreeModelEndBatch(this));
1335 } 1336 }
1336 } 1337 }
OLDNEW
« no previous file with comments | « chrome/browser/browsing_data/cookies_tree_model.h ('k') | chrome/browser/chrome_content_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698