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/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 <map> | 9 #include <map> |
10 #include <vector> | 10 #include <vector> |
(...skipping 1020 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1031 PopulateIndexedDBInfoWithFilter(data_container(), ¬ifier, filter); | 1031 PopulateIndexedDBInfoWithFilter(data_container(), ¬ifier, filter); |
1032 PopulateFileSystemInfoWithFilter(data_container(), ¬ifier, filter); | 1032 PopulateFileSystemInfoWithFilter(data_container(), ¬ifier, filter); |
1033 PopulateQuotaInfoWithFilter(data_container(), ¬ifier, filter); | 1033 PopulateQuotaInfoWithFilter(data_container(), ¬ifier, filter); |
1034 PopulateChannelIDInfoWithFilter(data_container(), ¬ifier, filter); | 1034 PopulateChannelIDInfoWithFilter(data_container(), ¬ifier, filter); |
1035 PopulateServiceWorkerUsageInfoWithFilter(data_container(), ¬ifier, filter); | 1035 PopulateServiceWorkerUsageInfoWithFilter(data_container(), ¬ifier, filter); |
1036 } | 1036 } |
1037 | 1037 |
1038 #if defined(ENABLE_EXTENSIONS) | 1038 #if defined(ENABLE_EXTENSIONS) |
1039 const extensions::ExtensionSet* CookiesTreeModel::ExtensionsProtectingNode( | 1039 const extensions::ExtensionSet* CookiesTreeModel::ExtensionsProtectingNode( |
1040 const CookieTreeNode& cookie_node) { | 1040 const CookieTreeNode& cookie_node) { |
1041 if (!special_storage_policy_) | 1041 if (!special_storage_policy_.get()) |
1042 return NULL; | 1042 return NULL; |
1043 | 1043 |
1044 CookieTreeNode::DetailedInfo info = cookie_node.GetDetailedInfo(); | 1044 CookieTreeNode::DetailedInfo info = cookie_node.GetDetailedInfo(); |
1045 | 1045 |
1046 if (!TypeIsProtected(info.node_type)) | 1046 if (!TypeIsProtected(info.node_type)) |
1047 return NULL; | 1047 return NULL; |
1048 | 1048 |
1049 DCHECK(!info.origin.is_empty()); | 1049 DCHECK(!info.origin.is_empty()); |
1050 return special_storage_policy_->ExtensionsProtectingOrigin(info.origin); | 1050 return special_storage_policy_->ExtensionsProtectingOrigin(info.origin); |
1051 } | 1051 } |
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1436 | 1436 |
1437 void CookiesTreeModel::NotifyObserverEndBatch() { | 1437 void CookiesTreeModel::NotifyObserverEndBatch() { |
1438 // Only notify the observers if this is the outermost call to EndBatch() if | 1438 // Only notify the observers if this is the outermost call to EndBatch() if |
1439 // called in a nested manner. | 1439 // called in a nested manner. |
1440 if (--batch_update_ == 0) { | 1440 if (--batch_update_ == 0) { |
1441 FOR_EACH_OBSERVER(Observer, | 1441 FOR_EACH_OBSERVER(Observer, |
1442 cookies_observer_list_, | 1442 cookies_observer_list_, |
1443 TreeModelEndBatch(this)); | 1443 TreeModelEndBatch(this)); |
1444 } | 1444 } |
1445 } | 1445 } |
OLD | NEW |