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

Side by Side Diff: chrome/browser/cookies_tree_model.h

Issue 8383004: Adding CookieSettings for storing cookie content settings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing the rebase. Created 9 years, 1 month 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 | Annotate | Revision Log
OLDNEW
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 #ifndef CHROME_BROWSER_COOKIES_TREE_MODEL_H_ 5 #ifndef CHROME_BROWSER_COOKIES_TREE_MODEL_H_
6 #define CHROME_BROWSER_COOKIES_TREE_MODEL_H_ 6 #define CHROME_BROWSER_COOKIES_TREE_MODEL_H_
7 #pragma once 7 #pragma once
8 8
9 // TODO(viettrungluu): This header file #includes far too much and has too much 9 // TODO(viettrungluu): This header file #includes far too much and has too much
10 // inline code (which shouldn't be inline). 10 // inline code (which shouldn't be inline).
(...skipping 10 matching lines...) Expand all
21 #include "chrome/browser/browsing_data_database_helper.h" 21 #include "chrome/browser/browsing_data_database_helper.h"
22 #include "chrome/browser/browsing_data_file_system_helper.h" 22 #include "chrome/browser/browsing_data_file_system_helper.h"
23 #include "chrome/browser/browsing_data_indexed_db_helper.h" 23 #include "chrome/browser/browsing_data_indexed_db_helper.h"
24 #include "chrome/browser/browsing_data_local_storage_helper.h" 24 #include "chrome/browser/browsing_data_local_storage_helper.h"
25 #include "chrome/browser/browsing_data_quota_helper.h" 25 #include "chrome/browser/browsing_data_quota_helper.h"
26 #include "chrome/common/content_settings.h" 26 #include "chrome/common/content_settings.h"
27 #include "net/base/cookie_monster.h" 27 #include "net/base/cookie_monster.h"
28 #include "ui/base/models/tree_node_model.h" 28 #include "ui/base/models/tree_node_model.h"
29 29
30 class BrowsingDataCookieHelper; 30 class BrowsingDataCookieHelper;
31 class CookieSettings;
31 class CookiesTreeModel; 32 class CookiesTreeModel;
32 class CookieTreeAppCacheNode; 33 class CookieTreeAppCacheNode;
33 class CookieTreeAppCachesNode; 34 class CookieTreeAppCachesNode;
34 class CookieTreeCookieNode; 35 class CookieTreeCookieNode;
35 class CookieTreeCookiesNode; 36 class CookieTreeCookiesNode;
36 class CookieTreeDatabaseNode; 37 class CookieTreeDatabaseNode;
37 class CookieTreeDatabasesNode; 38 class CookieTreeDatabasesNode;
38 class CookieTreeFileSystemsNode; 39 class CookieTreeFileSystemsNode;
39 class CookieTreeFileSystemNode; 40 class CookieTreeFileSystemNode;
40 class CookieTreeLocalStorageNode; 41 class CookieTreeLocalStorageNode;
41 class CookieTreeLocalStoragesNode; 42 class CookieTreeLocalStoragesNode;
42 class CookieTreeQuotaNode; 43 class CookieTreeQuotaNode;
43 class CookieTreeSessionStorageNode; 44 class CookieTreeSessionStorageNode;
44 class CookieTreeSessionStoragesNode; 45 class CookieTreeSessionStoragesNode;
45 class CookieTreeIndexedDBNode; 46 class CookieTreeIndexedDBNode;
46 class CookieTreeIndexedDBsNode; 47 class CookieTreeIndexedDBsNode;
47 class CookieTreeOriginNode; 48 class CookieTreeOriginNode;
48 class HostContentSettingsMap;
49 49
50 // CookieTreeNode ------------------------------------------------------------- 50 // CookieTreeNode -------------------------------------------------------------
51 // The base node type in the Cookies, Databases, and Local Storage options 51 // The base node type in the Cookies, Databases, and Local Storage options
52 // view, from which all other types are derived. Specialized from TreeNode in 52 // view, from which all other types are derived. Specialized from TreeNode in
53 // that it has a notion of deleting objects stored in the profile, and being 53 // that it has a notion of deleting objects stored in the profile, and being
54 // able to have its children do the same. 54 // able to have its children do the same.
55 class CookieTreeNode : public ui::TreeNode<CookieTreeNode> { 55 class CookieTreeNode : public ui::TreeNode<CookieTreeNode> {
56 public: 56 public:
57 // Used to pull out information for the InfoView (the details display below 57 // Used to pull out information for the InfoView (the details display below
58 // the tree control.) 58 // the tree control.)
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 CookieTreeLocalStoragesNode* GetOrCreateLocalStoragesNode(); 221 CookieTreeLocalStoragesNode* GetOrCreateLocalStoragesNode();
222 CookieTreeSessionStoragesNode* GetOrCreateSessionStoragesNode(); 222 CookieTreeSessionStoragesNode* GetOrCreateSessionStoragesNode();
223 CookieTreeAppCachesNode* GetOrCreateAppCachesNode(); 223 CookieTreeAppCachesNode* GetOrCreateAppCachesNode();
224 CookieTreeIndexedDBsNode* GetOrCreateIndexedDBsNode(); 224 CookieTreeIndexedDBsNode* GetOrCreateIndexedDBsNode();
225 CookieTreeFileSystemsNode* GetOrCreateFileSystemsNode(); 225 CookieTreeFileSystemsNode* GetOrCreateFileSystemsNode();
226 CookieTreeQuotaNode* UpdateOrCreateQuotaNode( 226 CookieTreeQuotaNode* UpdateOrCreateQuotaNode(
227 std::list<BrowsingDataQuotaHelper::QuotaInfo>::iterator quota_info); 227 std::list<BrowsingDataQuotaHelper::QuotaInfo>::iterator quota_info);
228 228
229 // Creates an content exception for this origin of type 229 // Creates an content exception for this origin of type
230 // CONTENT_SETTINGS_TYPE_COOKIES. 230 // CONTENT_SETTINGS_TYPE_COOKIES.
231 void CreateContentException(HostContentSettingsMap* content_settings, 231 void CreateContentException(CookieSettings* cookie_settings,
232 ContentSetting setting) const; 232 ContentSetting setting) const;
233 233
234 // True if a content exception can be created for this origin. 234 // True if a content exception can be created for this origin.
235 bool CanCreateContentException() const; 235 bool CanCreateContentException() const;
236 236
237 private: 237 private:
238 // Pointers to the cookies, databases, local and session storage and appcache 238 // Pointers to the cookies, databases, local and session storage and appcache
239 // nodes. When we build up the tree we need to quickly get a reference to 239 // nodes. When we build up the tree we need to quickly get a reference to
240 // the COOKIES node to add children. Checking each child and interrogating 240 // the COOKIES node to add children. Checking each child and interrogating
241 // them to see if they are a COOKIES, APPCACHES, DATABASES etc node seems 241 // them to see if they are a COOKIES, APPCACHES, DATABASES etc node seems
(...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after
675 friend class CookieTreeLocalStorageNode; 675 friend class CookieTreeLocalStorageNode;
676 friend class CookieTreeSessionStorageNode; 676 friend class CookieTreeSessionStorageNode;
677 friend class CookieTreeIndexedDBNode; 677 friend class CookieTreeIndexedDBNode;
678 friend class CookieTreeFileSystemNode; 678 friend class CookieTreeFileSystemNode;
679 friend class CookieTreeQuotaNode; 679 friend class CookieTreeQuotaNode;
680 680
681 DISALLOW_COPY_AND_ASSIGN(CookiesTreeModel); 681 DISALLOW_COPY_AND_ASSIGN(CookiesTreeModel);
682 }; 682 };
683 683
684 #endif // CHROME_BROWSER_COOKIES_TREE_MODEL_H_ 684 #endif // CHROME_BROWSER_COOKIES_TREE_MODEL_H_
OLDNEW
« no previous file with comments | « chrome/browser/content_settings/tab_specific_content_settings.cc ('k') | chrome/browser/cookies_tree_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698