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

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

Issue 12087120: Revert 179987 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 10 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_REMOVER_H_ 5 #ifndef CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_REMOVER_H_
6 #define CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_REMOVER_H_ 6 #define CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_REMOVER_H_
7 7
8 #include <set> 8 #include <set>
9 9
10 #include "base/gtest_prod_util.h" 10 #include "base/gtest_prod_util.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 } 43 }
44 44
45 namespace dom_storage { 45 namespace dom_storage {
46 struct LocalStorageUsageInfo; 46 struct LocalStorageUsageInfo;
47 struct SessionStorageUsageInfo; 47 struct SessionStorageUsageInfo;
48 } 48 }
49 49
50 // BrowsingDataRemover is responsible for removing data related to browsing: 50 // BrowsingDataRemover is responsible for removing data related to browsing:
51 // visits in url database, downloads, cookies ... 51 // visits in url database, downloads, cookies ...
52 52
53 class BrowsingDataRemover : public content::NotificationObserver 53 class BrowsingDataRemover : public content::NotificationObserver,
54 #if defined(ENABLE_PLUGINS) 54 #if defined(ENABLE_PLUGINS)
55 , public PepperFlashSettingsManager::Client 55 public PepperFlashSettingsManager::Client,
56 #endif 56 #endif
57 { 57 public base::WaitableEventWatcher::Delegate {
58 public: 58 public:
59 // Time period ranges available when doing browsing data removals. 59 // Time period ranges available when doing browsing data removals.
60 enum TimePeriod { 60 enum TimePeriod {
61 LAST_HOUR = 0, 61 LAST_HOUR = 0,
62 LAST_DAY, 62 LAST_DAY,
63 LAST_WEEK, 63 LAST_WEEK,
64 FOUR_WEEKS, 64 FOUR_WEEKS,
65 EVERYTHING 65 EVERYTHING
66 }; 66 };
67 67
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 virtual ~BrowsingDataRemover(); 203 virtual ~BrowsingDataRemover();
204 204
205 // content::NotificationObserver method. Callback when TemplateURLService has 205 // content::NotificationObserver method. Callback when TemplateURLService has
206 // finished loading. Deletes the entries from the model, and if we're not 206 // finished loading. Deletes the entries from the model, and if we're not
207 // waiting on anything else notifies observers and deletes this 207 // waiting on anything else notifies observers and deletes this
208 // BrowsingDataRemover. 208 // BrowsingDataRemover.
209 virtual void Observe(int type, 209 virtual void Observe(int type,
210 const content::NotificationSource& source, 210 const content::NotificationSource& source,
211 const content::NotificationDetails& details) OVERRIDE; 211 const content::NotificationDetails& details) OVERRIDE;
212 212
213 // WaitableEventWatcher implementation.
213 // Called when plug-in data has been cleared. Invokes NotifyAndDeleteIfDone. 214 // Called when plug-in data has been cleared. Invokes NotifyAndDeleteIfDone.
214 void OnWaitableEventSignaled(base::WaitableEvent* waitable_event); 215 virtual void OnWaitableEventSignaled(
216 base::WaitableEvent* waitable_event) OVERRIDE;
215 217
216 #if defined(ENABLE_PLUGINS) 218 #if defined(ENABLE_PLUGINS)
217 // PepperFlashSettingsManager::Client implementation. 219 // PepperFlashSettingsManager::Client implementation.
218 virtual void OnDeauthorizeContentLicensesCompleted(uint32 request_id, 220 virtual void OnDeauthorizeContentLicensesCompleted(uint32 request_id,
219 bool success) OVERRIDE; 221 bool success) OVERRIDE;
220 #endif 222 #endif
221 223
222 // Removes the specified items related to browsing for a specific host. If the 224 // Removes the specified items related to browsing for a specific host. If the
223 // provided |origin| is empty, data is removed for all origins. The 225 // provided |origin| is empty, data is removed for all origins. The
224 // |origin_set_mask| parameter defines the set of origins from which data 226 // |origin_set_mask| parameter defines the set of origins from which data
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
413 415
414 ObserverList<Observer> observer_list_; 416 ObserverList<Observer> observer_list_;
415 417
416 // Used if we need to clear history. 418 // Used if we need to clear history.
417 CancelableTaskTracker history_task_tracker_; 419 CancelableTaskTracker history_task_tracker_;
418 420
419 DISALLOW_COPY_AND_ASSIGN(BrowsingDataRemover); 421 DISALLOW_COPY_AND_ASSIGN(BrowsingDataRemover);
420 }; 422 };
421 423
422 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_REMOVER_H_ 424 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_REMOVER_H_
OLDNEW
« no previous file with comments | « base/synchronization/waitable_event_watcher_win.cc ('k') | chrome/browser/browsing_data/browsing_data_remover.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698