|
Split browsing data masks between content and embedder
As a part of the refactoring to move content-related browsing data
infrastructure to content, we split BrowsingDataRemover::RemoveDataMask
and BrowsingDataHelper::OriginTypeMask between content and embedder.
The CL consists of the following steps:
1. BrowsingDataRemover::RemoveDataMask now only contains content datatypes.
Chrome-specific datatypes are moved to ChromeBrowsingDataRemoverDelegate.
The enum in ChromeBrowsingDataRemoverDelegate also copies all values
from BrowsingDataRemover so that this enum inheritance better mimics
class inheritance. Note that this is a second attempt at this change, following
the discussion in https://codereview.chromium.org/2697123004/ where we tried
converting enums into pointers first.
The concept of FILTERABLE_DATATYPES has been moved to
ChromeBrowsingDataRemoverDelegate, since all content data types are filterable.
2. The same exercise is done for BrowsingDataHelper::OriginTypeMask. Its
first two items, UNPROTECTED_WEB and PROTECTED_WEB correspond to the boolean
returned by content::SpecialStoragePolicy::IsProtected(). Therefore, they
are moved to content as a new enum in BrowsingDataRemover. The third item,
EXTENSION, is a Chrome-specific concept and stays in chrome/ code, as a new
enum in ChromeBrowsingDataRemoverDelegate.
BrowsingDataRemoverImpl is now able to tell about each origin whether it is
UNPROTECTED_WEB or PROTECTED_WEB. It delegates the decision what is an
EXTENSION to ChromeBrowsingDataRemoverDelegate. A new method has been added
to the BrowsingDataRemoverDelegate for this purpose.
BrowsingDataHelper now serves no other purpose than recognizing webby and
extension URLs for various classes in browsing_data/ and can be eventually
deprecated (though doing so in this CL would significantly blow it in size).
The behavior of UNPROTECTED_WEB and PROTECTED_WEB is already sufficiently
tested in StoragePartition-related tests of BrowsingDataRemoverTest. We just
had to replace MockExtensionSpecialStoragePolicy with the regular
MockSpecialStoragePolicy. Testcases from BrowsingDataHelperTest have been moved
to ChromeBrowsingDataRemoverDelegateTest to cover the remaining EXTENSION type.
3. Since BrowsingDataRemover and ChromeBrowsingDataRemoverDelegate now host
both the data type and origin type enums, we changed the naming to call out
the difference; all data types are now prefixed with DATA_TYPE, all origin
types with ORIGIN_TYPE.
4. All other files contain equivalent replacements.
TBR=dbeam@chromium.org,jochen@chromium.org
BUG= 668114
Review-Url: https://codereview.chromium.org/2733393003
Cr-Commit-Position: refs/heads/master@{#456757}
Committed: https://chromium.googlesource.com/chromium/src/+/1c2b3ca05716cc40a8a89f51527b0eef52dddde6
Total comments: 5
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+1245 lines, -1010 lines) |
Patch |
|
M |
chrome/browser/android/preferences/pref_service_bridge.cc
|
View
|
1
2
3
4
5
6
7
8
9
|
5 chunks |
+16 lines, -13 lines |
0 comments
|
Download
|
|
M |
chrome/browser/android/signin/signin_manager_android.cc
|
View
|
1
|
2 chunks |
+5 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_helper.h
|
View
|
|
2 chunks |
+8 lines, -17 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_helper.cc
|
View
|
|
2 chunks |
+1 line, -27 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_helper_unittest.cc
|
View
|
|
4 chunks |
+0 lines, -81 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_remover.h
|
View
|
|
2 chunks |
+40 lines, -75 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_remover_browsertest.cc
|
View
|
1
2
3
4
5
6
7
8
|
11 chunks |
+15 lines, -14 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_remover_delegate.h
|
View
|
|
1 chunk |
+15 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_remover_impl.h
|
View
|
|
1 chunk |
+4 lines, -1 line |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_remover_impl.cc
|
View
|
1
2
3
4
5
6
7
8
|
13 chunks |
+74 lines, -54 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/browsing_data_remover_impl_unittest.cc
|
View
|
1
2
3
4
5
6
7
8
|
36 chunks |
+276 lines, -291 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/chrome_browsing_data_remover_delegate.h
|
View
|
1
2
3
4
5
6
7
8
|
3 chunks |
+102 lines, -1 line |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/chrome_browsing_data_remover_delegate.cc
|
View
|
1
2
3
4
5
6
7
8
|
19 chunks |
+101 lines, -50 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/chrome_browsing_data_remover_delegate_unittest.cc
|
View
|
1
2
3
4
5
6
7
8
|
46 chunks |
+261 lines, -119 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/mock_browsing_data_remover.h
|
View
|
|
1 chunk |
+6 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/browsing_data/mock_browsing_data_remover.cc
|
View
|
|
2 chunks |
+7 lines, -2 lines |
0 comments
|
Download
|
|
M |
chrome/browser/chrome_content_browser_client.cc
|
View
|
1
2
3
4
5
6
7
8
9
|
6 chunks |
+18 lines, -16 lines |
0 comments
|
Download
|
|
M |
chrome/browser/chrome_content_browser_client_unittest.cc
|
View
|
1
2
3
4
5
6
7
|
4 chunks |
+41 lines, -33 lines |
0 comments
|
Download
|
|
M |
chrome/browser/chromeos/profiles/profile_helper.cc
|
View
|
|
2 chunks |
+4 lines, -2 lines |
0 comments
|
Download
|
|
M |
chrome/browser/extensions/api/browsing_data/browsing_data_api.cc
|
View
|
1
2
3
4
5
6
7
8
|
10 chunks |
+43 lines, -38 lines |
0 comments
|
Download
|
|
M |
chrome/browser/extensions/api/browsing_data/browsing_data_test.cc
|
View
|
1
2
3
4
5
6
7
8
|
9 chunks |
+133 lines, -117 lines |
0 comments
|
Download
|
|
M |
chrome/browser/net/errorpage_browsertest.cc
|
View
|
1
2
3
4
5
6
7
8
|
3 chunks |
+5 lines, -4 lines |
0 comments
|
Download
|
|
M |
chrome/browser/net/predictor_browsertest.cc
|
View
|
1
2
3
4
5
6
7
8
|
2 chunks |
+3 lines, -2 lines |
0 comments
|
Download
|
|
M |
chrome/browser/net/sdch_browsertest.cc
|
View
|
1
2
3
4
5
6
7
8
|
3 chunks |
+6 lines, -4 lines |
0 comments
|
Download
|
|
M |
chrome/browser/predictors/resource_prefetch_predictor_browsertest.cc
|
View
|
1
2
3
4
5
6
7
8
|
2 chunks |
+4 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/prerender/prerender_browsertest.cc
|
View
|
1
2
3
4
5
6
7
8
|
4 chunks |
+6 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/profile_resetter/profile_resetter.cc
|
View
|
1
2
3
4
5
6
7
|
2 chunks |
+7 lines, -5 lines |
0 comments
|
Download
|
|
M |
chrome/browser/profiles/profiles_state.cc
|
View
|
|
2 chunks |
+3 lines, -1 line |
0 comments
|
Download
|
|
M |
chrome/browser/push_messaging/push_messaging_browsertest.cc
|
View
|
1
2
3
4
5
6
7
8
9
|
2 chunks |
+5 lines, -3 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ssl/chrome_ssl_host_state_delegate_test.cc
|
View
|
1
2
3
4
5
6
7
8
|
2 chunks |
+8 lines, -7 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/browser_commands.cc
|
View
|
1
2
3
4
5
6
7
8
|
2 chunks |
+3 lines, -2 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/webui/net_internals/net_internals_ui.cc
|
View
|
1
2
3
4
5
6
7
8
|
2 chunks |
+3 lines, -2 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/webui/options/clear_browser_data_handler.cc
|
View
|
1
2
3
4
5
6
7
8
|
2 chunks |
+11 lines, -10 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/webui/settings/settings_clear_browsing_data_handler.cc
|
View
|
1
2
3
4
5
6
7
8
|
2 chunks |
+11 lines, -10 lines |
0 comments
|
Download
|
Total messages: 71 (58 generated)
|