Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade from Chromium 88.0.4315.7 to Chromium 88.0.4324.51. #7408

Merged
merged 66 commits into from
Jan 7, 2021
Merged
Changes from 1 commit
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
145fb0e
Updated patches from Chromium 88.0.4315.7 to Chromium 88.0.4324.11.
mariospr Dec 9, 2020
4c931e3
Conflict-resolved patches from Chromium 88.0.4315.7 to Chromium 88.0.…
mariospr Dec 9, 2020
a9f1d28
Dropped patches no longer necessary in Chromium 88.0.4324.11
mariospr Nov 20, 2020
c9fbe12
Updated strings for Chromium 88.0.4324.11.
mariospr Nov 20, 2020
6e64e31
Move changes for permission_request.h into permission_request_enums.h
mariospr Nov 20, 2020
cd55dd8
Use views::PressedCallback instead of views::ButtonListener
mkarolin Nov 20, 2020
73199ae
IWYU.
mkarolin Nov 20, 2020
bfe25c8
PermissionRequest::PermissionGranted sig. changed.
mkarolin Nov 20, 2020
c51dc2f
CreateAndSwitchToNewProfile was removed.
mkarolin Nov 20, 2020
e87df65
SearchProviderObserver::is_google() is now virtual.
mkarolin Nov 20, 2020
6947700
Resource identifier was removed from HostContentSettingsMap.
mkarolin Nov 20, 2020
596c1a2
base/bind_helpers.h -> callback_helpers.h.
mkarolin Nov 20, 2020
d2bf2c0
ui/webui/resources/css/ resources grdp is now auto-generated.
mkarolin Nov 20, 2020
b295cd1
"content_scripts" manifest keys changes.
mkarolin Nov 20, 2020
617b4dc
DOMTypedArray::lengthAsSizeT() -> length().
mkarolin Nov 20, 2020
0c2b58d
[WebUI] Adjusted rollup override paths.
mkarolin Nov 21, 2020
fcf850b
[Android] LayoutManager interface added to layouts module
samartnik Nov 23, 2020
e98b75a
[Android] Renamings and c-tor signature changes
samartnik Nov 23, 2020
f9a10d0
Add override for new method of network.mojom.WebSocketHandshakeClient
mariospr Nov 24, 2020
6936154
Adapt includes for base/test/bind_test_util.h to base/test/bind.h
mariospr Nov 24, 2020
d35a595
[Web UI]: Printing section was removed from Settings.
mkarolin Nov 25, 2020
8941583
New Tab button moved out of TabStrip.
mkarolin Nov 26, 2020
8625e10
[Android] IDS_TURN_OFF_SYNC string was removed
samartnik Nov 26, 2020
1daa5b9
[Android] Fixed lint errors
samartnik Nov 26, 2020
a8698d6
Updated patches from Chromium 88.0.4324.11 to Chromium 88.0.4324.27.
mkarolin Dec 2, 2020
befcd5b
Updated strings for 88.0.4324.27.
mkarolin Dec 3, 2020
0b289c6
Default avatar changes.
mkarolin Dec 7, 2020
7d2fdf9
Updated patches from Chromium 88.0.4324.27 to Chromium 88.0.4324.41.
mkarolin Dec 10, 2020
0d5d330
Updated strings for Chromium 88.0.4324.41.
mkarolin Dec 10, 2020
1fb0322
[Android] New param for share function
samartnik Dec 14, 2020
b16f6e4
Updated patches from Chromium 88.0.4324.41 to Chromium 88.0.4324.51.
mkarolin Dec 17, 2020
ad5ac25
Conflict-resolved patches from Chromium 88.0.4324.41 to Chromium 88.0…
mkarolin Dec 17, 2020
74cfd56
base/bind_helpers.h -> callback_helpers.h II.
mkarolin Dec 17, 2020
32a7855
[iOS] IOSChromeFieldTrials::SetupFeatureControllingFieldTrials change.
mkarolin Dec 17, 2020
1c94a1d
[iOS] Fixes NS_SWIFT_NAME annotation.
mkarolin Dec 18, 2020
c7b2ffe
Updated strings for Chromium 88.0.4324.51.
mkarolin Dec 18, 2020
e6fedc9
Migrate away from using ResourceIdentifier now that it's gone upstream
mariospr Dec 9, 2020
63b895a
Remove BraveSiteSettingsCounter, it's no longer necessary
mariospr Dec 10, 2020
a6d02f3
Minimize patching surface using chromium_src overrides
mariospr Dec 11, 2020
5ec0fbb
Make sure cookies-related changes are notified for Brave Shields
mariospr Dec 14, 2020
4e388c9
Register ContentSettingsTypes as persistent and drop BraveEphemeralPr…
mariospr Dec 15, 2020
7ba58ce
Remove code from old upstream that's not really needed now anymore
mariospr Dec 16, 2020
cc90b36
Remove "bs_" prefix from settings names and modify only those needed
mariospr Dec 16, 2020
2481e99
[Android] Updated values for BraveShieldsContentSettings
samartnik Dec 17, 2020
6ad9a01
Don't cleanup "plugins" preference before migrating Shields' settings
mariospr Dec 21, 2020
2e7cdfc
Migrate Shields settings from the former ResouceIdentifier-based system
mariospr Dec 21, 2020
91ad7aa
Don't add ContentSettingsTypes for FB, Twitter and LinkedIn embeds
mariospr Dec 22, 2020
e157832
Extract helper functions out of brave_content_settings_pref_provider.cc
mariospr Dec 22, 2020
076977f
Add unit test for the settings migration from PLUGIN + ResourceIdenti…
mariospr Dec 22, 2020
2ed2dbe
[Android] Fixed bytecode tests
samartnik Dec 23, 2020
d73889f
Add missing GN dependencies
mariospr Dec 28, 2020
31c7607
Removed no longer needed Flash-related unit browser tests
mariospr Dec 28, 2020
f040465
move plugins to a temporary pref value so we don't have to patch
bridiver Dec 29, 2020
585f653
subclass to remove patch for default provider
bridiver Dec 29, 2020
0dcdcb1
remove more patches
bridiver Dec 30, 2020
6b802fd
fix gn checks
bridiver Dec 31, 2020
7ba3c3f
Lint fixes.
mkarolin Jan 4, 2021
f6f6d30
Formatting fixes.
mkarolin Jan 4, 2021
7552e7d
Reverted formatting of BATBraveRewards.h.
mkarolin Jan 5, 2021
e7f1c8b
[iOS] Modified rpath for brave_rewards_ios_tests.
mkarolin Jan 6, 2021
8207ee2
[iOS] Disable WidgetKit extension.
mkarolin Jan 6, 2021
7c795ca
IsShieldsContentSettingsType is not used on iOS.
mkarolin Dec 28, 2020
b57ddbb
Reverted some ugly formatting.
mkarolin Jan 6, 2021
8519666
Bumped up histogram values for our ContentSettingsTypes.
mkarolin Jan 6, 2021
4bd1bb4
Prevent startup crash on iOS due to unregistered metrics prefs.
mkarolin Jan 6, 2021
ee1aebd
Prevent crash on iOS when modifying AUTOPLAY pref.
mkarolin Jan 6, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,48 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */

// Leave a gap between Chromium values and our values in the kHistogramValue
// array so that we don't have to renumber when new content settings types are
// added upstream.
namespace {

// Do not change the value arbitrarily. This variable is only used for the
// DCHECK in ContentSettingTypeToHistogramValue function below.
constexpr int kBraveValuesStart = 1000;

constexpr int brave_value(int incr) {
return kBraveValuesStart + incr;
}

} // namespace

// clang-format off
#define BRAVE_HISTOGRAM_VALUE_LIST \
{ContentSettingsType::BRAVE_ADS, 74}, \
{ContentSettingsType::BRAVE_COSMETIC_FILTERING, 75}, \
{ContentSettingsType::BRAVE_TRACKERS, 76}, \
{ContentSettingsType::BRAVE_HTTP_UPGRADABLE_RESOURCES, 77}, \
{ContentSettingsType::BRAVE_FINGERPRINTING_V2, 78}, \
{ContentSettingsType::BRAVE_SHIELDS, 79}, \
{ContentSettingsType::BRAVE_REFERRERS, 80}, \
{ContentSettingsType::BRAVE_COOKIES, 81},
#define BRAVE_HISTOGRAM_VALUE_LIST \
{ContentSettingsType::BRAVE_ADS, brave_value(0)}, \
{ContentSettingsType::BRAVE_COSMETIC_FILTERING, brave_value(1)}, \
{ContentSettingsType::BRAVE_TRACKERS, brave_value(2)}, \
{ContentSettingsType::BRAVE_HTTP_UPGRADABLE_RESOURCES, brave_value(3)}, \
{ContentSettingsType::BRAVE_FINGERPRINTING_V2, brave_value(4)}, \
{ContentSettingsType::BRAVE_SHIELDS, brave_value(5)}, \
{ContentSettingsType::BRAVE_REFERRERS, brave_value(6)}, \
{ContentSettingsType::BRAVE_COOKIES, brave_value(7)},
// clang-format on

#define BRAVE_IS_RENDERER_CONTENT_SETTING \
content_type == ContentSettingsType::AUTOPLAY ||

#define ContentSettingTypeToHistogramValue \
ContentSettingTypeToHistogramValue_ChromiumImpl

#include "../../../../../../components/content_settings/core/common/content_settings.cc"

#undef ContentSettingTypeToHistogramValue
#undef BRAVE_HISTOGRAM_VALUE_LIST
#undef BRAVE_IS_RENDERER_CONTENT_SETTING

int ContentSettingTypeToHistogramValue(ContentSettingsType content_setting,
size_t* num_values) {
DCHECK(static_cast<int>(ContentSettingsType::NUM_TYPES) < kBraveValuesStart);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jfyi this could be static_assert

return ContentSettingTypeToHistogramValue_ChromiumImpl(content_setting,
num_values);
}