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

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

Issue 1459793002: Android: Allow compiling browser without Java UI (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
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 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 REMOVE_WEBSQL = 1 << 11, 76 REMOVE_WEBSQL = 1 << 11,
77 REMOVE_CHANNEL_IDS = 1 << 12, 77 REMOVE_CHANNEL_IDS = 1 << 12,
78 REMOVE_CONTENT_LICENSES = 1 << 13, 78 REMOVE_CONTENT_LICENSES = 1 << 13,
79 REMOVE_SERVICE_WORKERS = 1 << 14, 79 REMOVE_SERVICE_WORKERS = 1 << 14,
80 REMOVE_SITE_USAGE_DATA = 1 << 15, 80 REMOVE_SITE_USAGE_DATA = 1 << 15,
81 // REMOVE_NOCHECKS intentionally does not check if the Profile's prohibited 81 // REMOVE_NOCHECKS intentionally does not check if the Profile's prohibited
82 // from deleting history or downloads. 82 // from deleting history or downloads.
83 REMOVE_NOCHECKS = 1 << 16, 83 REMOVE_NOCHECKS = 1 << 16,
84 REMOVE_WEBRTC_IDENTITY = 1 << 17, 84 REMOVE_WEBRTC_IDENTITY = 1 << 17,
85 REMOVE_CACHE_STORAGE = 1 << 18, 85 REMOVE_CACHE_STORAGE = 1 << 18,
86 #if defined(OS_ANDROID) 86 #if defined(ANDROID_JAVA_UI)
87 REMOVE_WEBAPP_DATA = 1 << 19, 87 REMOVE_WEBAPP_DATA = 1 << 19,
88 REMOVE_OFFLINE_PAGE_DATA = 1 << 20, 88 REMOVE_OFFLINE_PAGE_DATA = 1 << 20,
89 #endif 89 #endif
90 // The following flag is used only in tests. In normal usage, hosted app 90 // The following flag is used only in tests. In normal usage, hosted app
91 // data is controlled by the REMOVE_COOKIES flag, applied to the 91 // data is controlled by the REMOVE_COOKIES flag, applied to the
92 // protected-web origin. 92 // protected-web origin.
93 REMOVE_HOSTED_APP_DATA_TESTONLY = 1 << 31, 93 REMOVE_HOSTED_APP_DATA_TESTONLY = 1 << 31,
94 94
95 // "Site data" includes cookies, appcache, file systems, indexedDBs, local 95 // "Site data" includes cookies, appcache, file systems, indexedDBs, local
96 // storage, webSQL, service workers, cache storage, plugin data, web app 96 // storage, webSQL, service workers, cache storage, plugin data, web app
97 // data (on Android) and statistics about passwords. 97 // data (on Android) and statistics about passwords.
98 REMOVE_SITE_DATA = REMOVE_APPCACHE | REMOVE_COOKIES | REMOVE_FILE_SYSTEMS | 98 REMOVE_SITE_DATA = REMOVE_APPCACHE | REMOVE_COOKIES | REMOVE_FILE_SYSTEMS |
99 REMOVE_INDEXEDDB | 99 REMOVE_INDEXEDDB |
100 REMOVE_LOCAL_STORAGE | 100 REMOVE_LOCAL_STORAGE |
101 REMOVE_PLUGIN_DATA | 101 REMOVE_PLUGIN_DATA |
102 REMOVE_SERVICE_WORKERS | 102 REMOVE_SERVICE_WORKERS |
103 REMOVE_CACHE_STORAGE | 103 REMOVE_CACHE_STORAGE |
104 REMOVE_WEBSQL | 104 REMOVE_WEBSQL |
105 REMOVE_CHANNEL_IDS | 105 REMOVE_CHANNEL_IDS |
106 REMOVE_SITE_USAGE_DATA | 106 REMOVE_SITE_USAGE_DATA |
107 #if defined(OS_ANDROID) 107 #if defined(ANDROID_JAVA_UI)
108 REMOVE_WEBAPP_DATA | 108 REMOVE_WEBAPP_DATA |
109 REMOVE_OFFLINE_PAGE_DATA | 109 REMOVE_OFFLINE_PAGE_DATA |
110 #endif 110 #endif
111 REMOVE_WEBRTC_IDENTITY, 111 REMOVE_WEBRTC_IDENTITY,
112 112
113 // Includes all the available remove options. Meant to be used by clients 113 // Includes all the available remove options. Meant to be used by clients
114 // that wish to wipe as much data as possible from a Profile, to make it 114 // that wish to wipe as much data as possible from a Profile, to make it
115 // look like a new Profile. 115 // look like a new Profile.
116 REMOVE_ALL = REMOVE_SITE_DATA | REMOVE_CACHE | REMOVE_DOWNLOADS | 116 REMOVE_ALL = REMOVE_SITE_DATA | REMOVE_CACHE | REMOVE_DOWNLOADS |
117 REMOVE_FORM_DATA | 117 REMOVE_FORM_DATA |
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
390 void OnClearedAutofillOriginURLs(); 390 void OnClearedAutofillOriginURLs();
391 391
392 // Callback on UI thread when the storage partition related data are cleared. 392 // Callback on UI thread when the storage partition related data are cleared.
393 void OnClearedStoragePartitionData(); 393 void OnClearedStoragePartitionData();
394 394
395 #if defined(ENABLE_WEBRTC) 395 #if defined(ENABLE_WEBRTC)
396 // Callback on UI thread when the WebRTC logs have been deleted. 396 // Callback on UI thread when the WebRTC logs have been deleted.
397 void OnClearedWebRtcLogs(); 397 void OnClearedWebRtcLogs();
398 #endif 398 #endif
399 399
400 #if defined(OS_ANDROID) 400 #if defined(ANDROID_JAVA_UI)
401 // Callback on UI thread when the precache history has been cleared. 401 // Callback on UI thread when the precache history has been cleared.
402 void OnClearedPrecacheHistory(); 402 void OnClearedPrecacheHistory();
403 403
404 // Callback on UI thread when the webapp data has been cleared. 404 // Callback on UI thread when the webapp data has been cleared.
405 void OnClearedWebappData(); 405 void OnClearedWebappData();
406 406
407 // Callback on UI thread when the offline page data has been cleared. 407 // Callback on UI thread when the offline page data has been cleared.
408 void OnClearedOfflinePageData(); 408 void OnClearedOfflinePageData();
409 #endif 409 #endif
410 410
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
458 bool waiting_for_clear_hostname_resolution_cache_ = false; 458 bool waiting_for_clear_hostname_resolution_cache_ = false;
459 bool waiting_for_clear_keyword_data_ = false; 459 bool waiting_for_clear_keyword_data_ = false;
460 bool waiting_for_clear_nacl_cache_ = false; 460 bool waiting_for_clear_nacl_cache_ = false;
461 bool waiting_for_clear_network_predictor_ = false; 461 bool waiting_for_clear_network_predictor_ = false;
462 bool waiting_for_clear_networking_history_ = false; 462 bool waiting_for_clear_networking_history_ = false;
463 bool waiting_for_clear_passwords_ = false; 463 bool waiting_for_clear_passwords_ = false;
464 bool waiting_for_clear_passwords_stats_ = false; 464 bool waiting_for_clear_passwords_stats_ = false;
465 bool waiting_for_clear_platform_keys_ = false; 465 bool waiting_for_clear_platform_keys_ = false;
466 bool waiting_for_clear_plugin_data_ = false; 466 bool waiting_for_clear_plugin_data_ = false;
467 bool waiting_for_clear_pnacl_cache_ = false; 467 bool waiting_for_clear_pnacl_cache_ = false;
468 #if defined(OS_ANDROID) 468 #if defined(ANDROID_JAVA_UI)
469 bool waiting_for_clear_precache_history_ = false; 469 bool waiting_for_clear_precache_history_ = false;
470 bool waiting_for_clear_webapp_data_ = false; 470 bool waiting_for_clear_webapp_data_ = false;
471 bool waiting_for_clear_offline_page_data_ = false; 471 bool waiting_for_clear_offline_page_data_ = false;
472 #endif 472 #endif
473 bool waiting_for_clear_storage_partition_data_ = false; 473 bool waiting_for_clear_storage_partition_data_ = false;
474 #if defined(ENABLE_WEBRTC) 474 #if defined(ENABLE_WEBRTC)
475 bool waiting_for_clear_webrtc_logs_ = false; 475 bool waiting_for_clear_webrtc_logs_ = false;
476 #endif 476 #endif
477 477
478 // The removal mask for the current removal operation. 478 // The removal mask for the current removal operation.
479 int remove_mask_ = 0; 479 int remove_mask_ = 0;
480 480
481 // From which types of origins should we remove data? 481 // From which types of origins should we remove data?
482 int origin_type_mask_ = 0; 482 int origin_type_mask_ = 0;
483 483
484 base::ObserverList<Observer> observer_list_; 484 base::ObserverList<Observer> observer_list_;
485 485
486 // Used if we need to clear history. 486 // Used if we need to clear history.
487 base::CancelableTaskTracker history_task_tracker_; 487 base::CancelableTaskTracker history_task_tracker_;
488 488
489 scoped_ptr<TemplateURLService::Subscription> template_url_sub_; 489 scoped_ptr<TemplateURLService::Subscription> template_url_sub_;
490 490
491 // We do not own this. 491 // We do not own this.
492 content::StoragePartition* storage_partition_for_testing_ = nullptr; 492 content::StoragePartition* storage_partition_for_testing_ = nullptr;
493 493
494 DISALLOW_COPY_AND_ASSIGN(BrowsingDataRemover); 494 DISALLOW_COPY_AND_ASSIGN(BrowsingDataRemover);
495 }; 495 };
496 496
497 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_REMOVER_H_ 497 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_REMOVER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698