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

Side by Side Diff: chrome/browser/browsing_data/browsing_data_quota_helper_impl.h

Issue 10948006: Cleanup: quota::HostQuotaCallback do not need to pass host and type as arguments (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed unittests somehow missed in previous patch Created 8 years, 3 months 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) 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 #ifndef CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_QUOTA_HELPER_IMPL_H_ 5 #ifndef CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_QUOTA_HELPER_IMPL_H_
6 #define CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_QUOTA_HELPER_IMPL_H_ 6 #define CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_QUOTA_HELPER_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 void ProcessPendingHosts(); 44 void ProcessPendingHosts();
45 void GetHostUsage(const std::string& host, quota::StorageType type); 45 void GetHostUsage(const std::string& host, quota::StorageType type);
46 46
47 // Callback function for GetHostUsage. 47 // Callback function for GetHostUsage.
48 void GotHostUsage(const std::string& host, 48 void GotHostUsage(const std::string& host,
49 quota::StorageType type, 49 quota::StorageType type,
50 int64 usage); 50 int64 usage);
51 51
52 void OnComplete(); 52 void OnComplete();
53 void DidRevokeHostQuota(quota::QuotaStatusCode status, 53 void DidRevokeHostQuota(const std::string& host,
54 const std::string& host,
55 quota::StorageType type, 54 quota::StorageType type,
55 quota::QuotaStatusCode status,
56 int64 quota); 56 int64 quota);
57 57
58 scoped_refptr<quota::QuotaManager> quota_manager_; 58 scoped_refptr<quota::QuotaManager> quota_manager_;
59 FetchResultCallback callback_; 59 FetchResultCallback callback_;
60 60
61 typedef std::set<std::pair<std::string, quota::StorageType> > PendingHosts; 61 typedef std::set<std::pair<std::string, quota::StorageType> > PendingHosts;
62 PendingHosts pending_hosts_; 62 PendingHosts pending_hosts_;
63 std::map<std::string, QuotaInfo> quota_info_; 63 std::map<std::string, QuotaInfo> quota_info_;
64 64
65 bool is_fetching_; 65 bool is_fetching_;
66 66
67 scoped_refptr<base::MessageLoopProxy> ui_thread_; 67 scoped_refptr<base::MessageLoopProxy> ui_thread_;
68 scoped_refptr<base::MessageLoopProxy> io_thread_; 68 scoped_refptr<base::MessageLoopProxy> io_thread_;
69 base::WeakPtrFactory<BrowsingDataQuotaHelperImpl> weak_factory_; 69 base::WeakPtrFactory<BrowsingDataQuotaHelperImpl> weak_factory_;
70 70
71 friend class BrowsingDataQuotaHelper; 71 friend class BrowsingDataQuotaHelper;
72 friend class BrowsingDataQuotaHelperTest; 72 friend class BrowsingDataQuotaHelperTest;
73 73
74 DISALLOW_COPY_AND_ASSIGN(BrowsingDataQuotaHelperImpl); 74 DISALLOW_COPY_AND_ASSIGN(BrowsingDataQuotaHelperImpl);
75 }; 75 };
76 76
77 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_QUOTA_HELPER_IMPL_H_ 77 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_QUOTA_HELPER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698