OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 COMPONENTS_BROWSING_DATA_CORE_HISTORY_NOTICE_UTILS_H_ | 5 #ifndef COMPONENTS_BROWSING_DATA_CORE_HISTORY_NOTICE_UTILS_H_ |
6 #define COMPONENTS_BROWSING_DATA_CORE_HISTORY_NOTICE_UTILS_H_ | 6 #define COMPONENTS_BROWSING_DATA_CORE_HISTORY_NOTICE_UTILS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
11 | 11 |
12 namespace history { | 12 namespace history { |
13 class WebHistoryService; | 13 class WebHistoryService; |
14 } | 14 } |
15 | 15 |
16 namespace sync_driver { | 16 namespace syncer { |
17 class SyncService; | 17 class SyncService; |
18 } | 18 } |
19 | 19 |
20 namespace version_info { | 20 namespace version_info { |
21 enum class Channel; | 21 enum class Channel; |
22 } | 22 } |
23 | 23 |
24 namespace browsing_data { | 24 namespace browsing_data { |
25 | 25 |
26 namespace testing { | 26 namespace testing { |
27 | 27 |
28 // TODO(crbug.com/595332): A boolean flag indicating that | 28 // TODO(crbug.com/595332): A boolean flag indicating that |
29 // ShouldShowNoticeAboutOtherFormsOfBrowsingHistory() should skip the query | 29 // ShouldShowNoticeAboutOtherFormsOfBrowsingHistory() should skip the query |
30 // for other forms of browsing history and just assume some such forms were | 30 // for other forms of browsing history and just assume some such forms were |
31 // found. Used only for testing. The default is false. | 31 // found. Used only for testing. The default is false. |
32 extern bool g_override_other_forms_of_browsing_history_query; | 32 extern bool g_override_other_forms_of_browsing_history_query; |
33 | 33 |
34 } // testing | 34 } // testing |
35 | 35 |
36 // Whether the Clear Browsing Data UI should show a notice about the existence | 36 // Whether the Clear Browsing Data UI should show a notice about the existence |
37 // of other forms of browsing history stored in user's account. The response | 37 // of other forms of browsing history stored in user's account. The response |
38 // is returned in a |callback|. | 38 // is returned in a |callback|. |
39 void ShouldShowNoticeAboutOtherFormsOfBrowsingHistory( | 39 void ShouldShowNoticeAboutOtherFormsOfBrowsingHistory( |
40 const sync_driver::SyncService* sync_service, | 40 const syncer::SyncService* sync_service, |
41 history::WebHistoryService* history_service, | 41 history::WebHistoryService* history_service, |
42 base::Callback<void(bool)> callback); | 42 base::Callback<void(bool)> callback); |
43 | 43 |
44 // Whether the Clear Browsing Data UI should popup a dialog with information | 44 // Whether the Clear Browsing Data UI should popup a dialog with information |
45 // about the existence of other forms of browsing history stored in user's | 45 // about the existence of other forms of browsing history stored in user's |
46 // account when the user deletes their browsing history for the first time. | 46 // account when the user deletes their browsing history for the first time. |
47 // The response is returned in a |callback|. The |channel| parameter | 47 // The response is returned in a |callback|. The |channel| parameter |
48 // must be provided for successful communication with the Sync server, but | 48 // must be provided for successful communication with the Sync server, but |
49 // the result does not depend on it. | 49 // the result does not depend on it. |
50 void ShouldPopupDialogAboutOtherFormsOfBrowsingHistory( | 50 void ShouldPopupDialogAboutOtherFormsOfBrowsingHistory( |
51 const sync_driver::SyncService* sync_service, | 51 const syncer::SyncService* sync_service, |
52 history::WebHistoryService* history_service, | 52 history::WebHistoryService* history_service, |
53 version_info::Channel channel, | 53 version_info::Channel channel, |
54 base::Callback<void(bool)> callback); | 54 base::Callback<void(bool)> callback); |
55 | 55 |
56 } // namespace browsing_data | 56 } // namespace browsing_data |
57 | 57 |
58 #endif // COMPONENTS_BROWSING_DATA_CORE_HISTORY_NOTICE_UTILS_H_ | 58 #endif // COMPONENTS_BROWSING_DATA_CORE_HISTORY_NOTICE_UTILS_H_ |
OLD | NEW |