| 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 #ifndef CHROME_BROWSER_BROWSING_DATA_REMOVER_H_ | 5 #ifndef CHROME_BROWSER_BROWSING_DATA_REMOVER_H_ |
| 6 #define CHROME_BROWSER_BROWSING_DATA_REMOVER_H_ | 6 #define CHROME_BROWSER_BROWSING_DATA_REMOVER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 | 10 |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 | 119 |
| 120 // Removes the specified items related to browsing. | 120 // Removes the specified items related to browsing. |
| 121 void Remove(int remove_mask); | 121 void Remove(int remove_mask); |
| 122 | 122 |
| 123 void AddObserver(Observer* observer); | 123 void AddObserver(Observer* observer); |
| 124 void RemoveObserver(Observer* observer); | 124 void RemoveObserver(Observer* observer); |
| 125 | 125 |
| 126 // Called when history deletion is done. | 126 // Called when history deletion is done. |
| 127 void OnHistoryDeletionDone(); | 127 void OnHistoryDeletionDone(); |
| 128 | 128 |
| 129 // Quota managed data uses a different bitmask for types than |
| 130 // BrowsingDataRemover uses. This method generates that mask. |
| 131 static int GenerateQuotaClientMask(int remove_mask); |
| 132 |
| 129 static bool is_removing() { return removing_; } | 133 static bool is_removing() { return removing_; } |
| 130 | 134 |
| 131 private: | 135 private: |
| 132 // The clear API needs to be able to toggle removing_ in order to test that | 136 // The clear API needs to be able to toggle removing_ in order to test that |
| 133 // only one BrowsingDataRemover instance can be called at a time. | 137 // only one BrowsingDataRemover instance can be called at a time. |
| 134 FRIEND_TEST_ALL_PREFIXES(ExtensionClearTest, OneAtATime); | 138 FRIEND_TEST_ALL_PREFIXES(ExtensionClearTest, OneAtATime); |
| 135 | 139 |
| 136 enum CacheState { | 140 enum CacheState { |
| 137 STATE_NONE, | 141 STATE_NONE, |
| 138 STATE_CREATE_MAIN, | 142 STATE_CREATE_MAIN, |
| (...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 | 292 |
| 289 ObserverList<Observer> observer_list_; | 293 ObserverList<Observer> observer_list_; |
| 290 | 294 |
| 291 // Used if we need to clear history. | 295 // Used if we need to clear history. |
| 292 CancelableRequestConsumer request_consumer_; | 296 CancelableRequestConsumer request_consumer_; |
| 293 | 297 |
| 294 DISALLOW_COPY_AND_ASSIGN(BrowsingDataRemover); | 298 DISALLOW_COPY_AND_ASSIGN(BrowsingDataRemover); |
| 295 }; | 299 }; |
| 296 | 300 |
| 297 #endif // CHROME_BROWSER_BROWSING_DATA_REMOVER_H_ | 301 #endif // CHROME_BROWSER_BROWSING_DATA_REMOVER_H_ |
| OLD | NEW |