Skip to content

Commit

Permalink
Merge pull request #22320 from brave/cr124
Browse files Browse the repository at this point in the history
Upgrade from Chromium 123 to Chromium 124.
  • Loading branch information
mkarolin committed Apr 10, 2024
1 parent 065ef46 commit 93e63c4
Show file tree
Hide file tree
Showing 609 changed files with 7,092 additions and 2,505 deletions.
2 changes: 1 addition & 1 deletion DEPS
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ deps = {
"third_party/bitcoin-core/src": "https://github.com/bitcoin/bitcoin.git@8105bce5b384c72cf08b25b7c5343622754e7337", # v25.0
"third_party/argon2/src": "https://github.com/P-H-C/phc-winner-argon2.git@62358ba2123abd17fccf2a108a301d4b52c01a7c",
"third_party/rapidjson/src": "https://github.com/Tencent/rapidjson.git@06d58b9e848c650114556a23294d0b6440078c61",
"third_party/reclient_configs/src": "https://github.com/EngFlow/reclient-configs.git@61ddd9705962a6c6c921b42c933451d4810aa28e",
"third_party/reclient_configs/src": "https://github.com/EngFlow/reclient-configs.git@21c8fe69ff771956c179847b8c1d9fd216181967",
'third_party/android_deps/libs/com_google_android_play_core': {
'packages': [
{
Expand Down
1 change: 1 addition & 0 deletions android/brave_java_sources.gni
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ brave_java_sources = [
"../../brave/android/java/org/chromium/chrome/browser/DormantUsersEngagementDialogFragment.java",
"../../brave/android/java/org/chromium/chrome/browser/InternetConnection.java",
"../../brave/android/java/org/chromium/chrome/browser/QRCodeShareDialogFragment.java",
"../../brave/android/java/org/chromium/chrome/browser/accessibility/settings/BraveAccessibilitySettings.java",
"../../brave/android/java/org/chromium/chrome/browser/app/BraveActivity.java",
"../../brave/android/java/org/chromium/chrome/browser/app/appmenu/AppMenuIconRowFooter.java",
"../../brave/android/java/org/chromium/chrome/browser/app/appmenu/BraveAppMenuPropertiesDelegateImpl.java",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,11 @@
</message>

<!-- Undo Bar -->
<message name="IDS_UNDO_BAR_GROUP_TABS_MESSAGE" desc="Message shown or announced when a group has been created.">
<ph name="TAB_COUNT">%1$s<ex>3</ex></ph> tabs grouped
<message name="IDS_UNDO_BAR_GROUP_TAB_MESSAGE" desc="Message shown or announced when a group has been created with a single tab.">
<ph name="TABS_COUNT_ONE">%1$s<ex>1</ex></ph> tab grouped
</message>
<message name="IDS_UNDO_BAR_GROUP_TABS_MESSAGE" desc="Message shown or announced when a group has been created with multiple tabs.">
<ph name="TABS_COUNT_MANY">%1$s<ex>3</ex></ph> tabs grouped
</message>

<!-- Bottom Tab Grid strings -->
Expand Down Expand Up @@ -222,11 +225,17 @@
<message name="IDS_ACCESSIBILITY_TAB_SWITCHER" desc="Accessibility string for Tab Switcher view. This string is announced when the Tab Switcher is shown to screen.">
Tab Switcher
</message>
<message name="IDS_ACCESSIBILITY_CLOSE_TAB_GROUP_BUTTON" desc="The accessibility text to read when the close button on a card representing a tab group is focused in grid tab switcher. When this close button is tapped, all tabs within the tab group will be closed. NUMBER_OF_TABS is the number of tabs within this group. Note that there are always at least two tabs in a group so plural form should always be used.">
Close tab group with <ph name="NUMBER_OF_TABS">%1$s<ex>2</ex></ph> tabs
<message name="IDS_ACCESSIBILITY_CLOSE_TAB_GROUP_BUTTON" desc="The accessibility text to read when the close button on a card representing a tab group is focused in grid tab switcher. When this close button is tapped, all tabs within the tab group will be closed. NUMBER_OF_TABS is the number of tabs within this group.">
{NUMBER_OF_TABS, plural,
=1 {Close tab group with <ph name="TABS_COUNT_ONE">%1$d<ex>1</ex></ph> tab.}
other {Close tab group with <ph name="TABS_COUNT_MANY">%1$d<ex>2</ex></ph> tabs.}
}
</message>
<message name="IDS_ACCESSIBILITY_CLOSE_TAB_GROUP_BUTTON_WITH_GROUP_NAME" desc="The accessibility text to read when the close button on a card representing a tab group is focused in grid tab switcher. When this close button is tapped, all tabs within the tab group will be closed. TITLE_OF_GROUP is the title of the group. NUMBER_OF_TABS is the number of tabs within this group. Note that there are always at least two tabs in a group so plural form should always be used.">
Close <ph name="TITLE_OF_GROUP">%1$s<ex>shopping</ex></ph> group with <ph name="NUMBER_OF_TABS">%2$s<ex>2</ex></ph> tabs
<message name="IDS_ACCESSIBILITY_CLOSE_TAB_GROUP_BUTTON_WITH_GROUP_NAME" desc="The accessibility text to read when the close button on a card representing a tab group is focused in grid tab switcher. When this close button is tapped, all tabs within the tab group will be closed. TITLE_OF_GROUP is the title of the group. NUMBER_OF_TABS is the number of tabs within this group.">
{NUMBER_OF_TABS, plural,
=1 {Close <ph name="TITLE_OF_GROUP">%1$s<ex>shopping</ex></ph> group with <ph name="TABS_COUNT_ONE">%2$d<ex>1</ex></ph> tab.}
other {Close <ph name="TITLE_OF_GROUP">%1$s<ex>shopping</ex></ph> group with <ph name="TABS_COUNT_MANY">%2$d<ex>2</ex></ph> tabs.}
}
</message>

<!-- Tab Selection Editor strings -->
Expand Down Expand Up @@ -332,23 +341,32 @@
<message name="IDS_TAB_GRID_DIALOG_TOOLBAR_EDIT_GROUP_NAME" desc="This text shows in the TabGridDialog toolbar menu as one menu item. When user selects this item, the group name field will be focused and the keyboard will show for users to edit the group name.">
Edit group name
</message>
<message name="IDS_TAB_GRID_DIALOG_TOOLBAR_EDIT_GROUP_COLOR" desc="This text shows in the TabGridDialog toolbar menu as one menu item. When user selects this item, a color picker popup window will appear and allow the user to update the color for this tab group.">
Edit group color
</message>

<!-- Tab Grid Dialog accessibility strings -->
<message name="IDS_ACCESSIBILITY_EXPAND_TAB_GROUP" desc="The accessibility text to read when a card representing a tab group is clicked in grid tab switcher. NUMBER_OF_TABS is the number of tabs within this group. Note that there are always at least two tabs in a group so plural form should always be used.">
Expand tab group with <ph name="NUMBER_OF_TABS">%1$s<ex>2</ex></ph> tabs.
<message name="IDS_ACCESSIBILITY_EXPAND_TAB_GROUP" desc="The accessibility text to read when a card representing a tab group is clicked in grid tab switcher. NUMBER_OF_TABS is the number of tabs within this group.">
{NUMBER_OF_TABS, plural,
=1 {Expand tab group with <ph name="TABS_COUNT_ONE">%1$d<ex>1</ex></ph> tab.}
other {Expand tab group with <ph name="TABS_COUNT_MANY">%1$d<ex>2</ex></ph> tabs.}
}
</message>
<message name="IDS_ACCESSIBILITY_EXPAND_TAB_GROUP_WITH_GROUP_NAME" desc="The accessibility text to read when a card representing a tab group is clicked in grid tab switcher. TITLE_OF_GROUP is the title of the group. NUMBER_OF_TABS is the number of tabs within this group. Note that there are always at least two tabs in a group so plural form should always be used.">
Expand <ph name="TITLE_OF_GROUP">%1$s<ex>Shopping cart</ex></ph> tab group with <ph name="NUMBER_OF_TABS">%2$s<ex>2</ex></ph> tabs.
<message name="IDS_ACCESSIBILITY_EXPAND_TAB_GROUP_WITH_GROUP_NAME" desc="The accessibility text to read when a card representing a tab group is clicked in grid tab switcher. TITLE_OF_GROUP is the title of the group. NUMBER_OF_TABS is the number of tabs within this group.">
{NUMBER_OF_TABS, plural,
=1 {Expand <ph name="TITLE_OF_GROUP">%1$s<ex>Shopping cart</ex></ph> tab group with <ph name="TABS_COUNT_ONE">%2$d<ex>1</ex></ph> tab.}
other {Expand <ph name="TITLE_OF_GROUP">%1$s<ex>Shopping cart</ex></ph> tab group with <ph name="TABS_COUNT_MANY">%2$d<ex>2</ex></ph> tabs.}
}
</message>
<message name="IDS_ACCESSIBILITY_DIALOG_BACK_BUTTON" desc="The accessibility text to read when the back button in the dialog is focused. When this button is tapped, the dialog will be hidden. NUMBER_OF_TABS is the number of tabs within this group. Note that after collapsing with one tab, that group becomes a tab.">
{TABS_COUNT, plural,
=1 {Collapse <ph name="TABS_COUNT_ONE">%1$d<ex>1</ex></ph> tab.}
other {Collapse tab group with <ph name="TABS_COUNT_MANY">%1$d<ex>2</ex></ph> tabs.}
}
</message>
<message name="IDS_ACCESSIBILITY_DIALOG_BACK_BUTTON_WITH_GROUP_NAME" desc="The accessibility text to read when the back button in the dialog is focused. When this button is tapped, the dialog will be hidden. TITLE_OF_GROUP is the title of the group. NUMBER_OF_TABS is the number of tabs within this group. Note that after collapsing with one tab, that group becomes a tab.">
<message name="IDS_ACCESSIBILITY_DIALOG_BACK_BUTTON_WITH_GROUP_NAME" desc="The accessibility text to read when the back button in the dialog is focused. When this button is tapped, the dialog will be hidden. TITLE_OF_GROUP is the title of the group. NUMBER_OF_TABS is the number of tabs within this group.">
{TABS_COUNT, plural,
=1 {Collapse <ph name="TABS_COUNT_ONE">%1$d<ex>1</ex></ph> tab.}
=1 {Collapse <ph name="TITLE_OF_GROUP">%1$s<ex>Shopping cart</ex></ph> tab group with <ph name="TABS_COUNT_ONE">%2$d<ex>1</ex></ph> tab.}
other {Collapse <ph name="TITLE_OF_GROUP">%1$s<ex>Shopping cart</ex></ph> tab group with <ph name="TABS_COUNT_MANY">%2$d<ex>2</ex></ph> tabs.}
}
</message>
Expand Down Expand Up @@ -637,6 +655,45 @@
<message name="IDS_ACCESSIBILITY_TAB_GROUPS" desc="Content description for the button to show tab groups UI.">
Tab groups
</message>
<message name="IDS_TAB_GROUPS_CREATED_AGO_NOW" desc="A subtitle on a row for a tab group. Explains the group was created less than a minute ago.">
Created just now
</message>
<message name="IDS_TAB_GROUPS_CREATED_AGO_MINUTES" desc="A subtitle on a row for a tab group. Explains how many minutes ago the group was created.">
{NUM_MINS, plural,
=1 {Created <ph name="NUM_MINS_ONE">%d<ex>1</ex></ph> minute ago}
other {Created <ph name="NUM_MINS_MANY">%d<ex>2</ex></ph> minutes ago}
}
</message>
<message name="IDS_TAB_GROUPS_CREATED_AGO_HOURS" desc="A subtitle on a row for a tab group. Explains how many hours ago the group was created.">
{NUM_HOURS, plural,
=1 {Created <ph name="NUM_HOURS_ONE">%d<ex>1</ex></ph> hour ago}
other {Created <ph name="NUM_HOURS_MANY">%d<ex>2</ex></ph> hours ago}
}
</message>
<message name="IDS_TAB_GROUPS_CREATED_AGO_DAYS" desc="A subtitle on a row for a tab group. Explains how many days ago the group was created.">
{NUM_DAYS, plural,
=1 {Created <ph name="NUM_DAYS_ONE">%d<ex>1</ex></ph> day ago}
other {Created <ph name="NUM_DAYS_MANY">%d<ex>2</ex></ph> days ago}
}
</message>
<message name="IDS_TAB_GROUPS_CREATED_AGO_WEEKS" desc="A subtitle on a row for a tab group. Explains how many weeks ago the group was created.">
{NUM_WEEKS, plural,
=1 {Created <ph name="NUM_WEEKS_ONE">%d<ex>1</ex></ph> week ago}
other {Created <ph name="NUM_WEEKS_MANY">%d<ex>2</ex></ph> weeks ago}
}
</message>
<message name="IDS_TAB_GROUPS_CREATED_AGO_MONTHS" desc="A subtitle on a row for a tab group. Explains how many months ago the group was created.">
{NUM_MONTHS, plural,
=1 {Created <ph name="NUM_MONTHS_ONE">%d<ex>1</ex></ph> month ago}
other {Created <ph name="NUM_MONTHS_MANY">%d<ex>2</ex></ph> months ago}
}
</message>
<message name="IDS_TAB_GROUPS_CREATED_AGO_YEARS" desc="A subtitle on a row for a tab group. Explains how many years ago the group was created.">
{NUM_MONTHS, plural,
=1 {Created <ph name="NUM_YEARS_ONE">%d<ex>1</ex></ph> year ago}
other {Created <ph name="NUM_YEARS_MANY">%d<ex>2</ex></ph> years ago}
}
</message>
</messages>
</release>
</grit>
1 change: 1 addition & 0 deletions android/java/apk_for_test.flags
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@
*** mTabCreatorManager;
*** mSnackbarManager;
*** mTabObscuringHandler;
*** mReadAloudControllerSupplier;
*** onOrientationChange(...);
*** updateBookmarkButtonStatus(...);
*** updateReloadState(...);
Expand Down
3 changes: 2 additions & 1 deletion android/java/org/chromium/chrome/browser/BraveHelper.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import org.chromium.base.ContextUtils;
import org.chromium.chrome.browser.preferences.BravePrefServiceBridge;
import org.chromium.chrome.browser.profiles.Profile;
import org.chromium.chrome.browser.profiles.ProfileManager;
import org.chromium.components.browser_ui.site_settings.WebsitePreferenceBridge;
import org.chromium.components.content_settings.ContentSettingValues;
import org.chromium.components.content_settings.ContentSettingsType;
Expand All @@ -29,7 +30,7 @@ public static void DisableFREDRP() {
public static void maybeMigrateSettings() {
// False is the default value, so we want to migrate it only when it's true.
if (BravePrefServiceBridge.getInstance().getDesktopModeEnabled()) {
Profile profile = Profile.getLastUsedRegularProfile();
Profile profile = ProfileManager.getLastUsedRegularProfile();
WebsitePreferenceBridge.setDefaultContentSetting(
profile, ContentSettingsType.REQUEST_DESKTOP_SITE, ContentSettingValues.ALLOW);
// Reset old flag to default value, so we don't migrate it anymore.
Expand Down
19 changes: 10 additions & 9 deletions android/java/org/chromium/chrome/browser/BraveIntentHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
import org.chromium.base.IntentUtils;
import org.chromium.base.Log;
import org.chromium.base.ThreadUtils;
import org.chromium.chrome.browser.profiles.Profile;
import org.chromium.chrome.browser.profiles.ProfileManager;
import org.chromium.chrome.browser.search_engines.TemplateUrlServiceFactory;
import org.chromium.content_public.browser.BrowserStartupController;

Expand Down Expand Up @@ -65,14 +65,15 @@ protected static String getWebSearchUrl(Intent intent) {
}

try {
return ThreadUtils.runOnUiThreadBlocking(new Callable<String>() {
@Override
public String call() {
return TemplateUrlServiceFactory
.getForProfile(Profile.getLastUsedRegularProfile())
.getUrlForSearchQuery(query);
}
});
return ThreadUtils.runOnUiThreadBlocking(
new Callable<String>() {
@Override
public String call() {
return TemplateUrlServiceFactory.getForProfile(
ProfileManager.getLastUsedRegularProfile())
.getUrlForSearchQuery(query);
}
});
} catch (ExecutionException e) {
Log.e(TAG, "Could not retrieve search query: " + e);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import org.chromium.chrome.browser.customtabs.CustomTabActivity;
import org.chromium.chrome.browser.preferences.ChromeSharedPreferences;
import org.chromium.chrome.browser.profiles.Profile;
import org.chromium.chrome.browser.profiles.ProfileManager;
import org.chromium.chrome.browser.tab.Tab;
import org.chromium.components.browser_ui.widget.RoundedIconGenerator;
import org.chromium.components.favicon.IconType;
Expand Down Expand Up @@ -235,7 +236,7 @@ public interface LargeIconReadyCallback {
public BraveRewardsHelper(Tab tab) {
mTab = tab;
assert mTab != null;
mProfile = Profile.getLastUsedRegularProfile();
mProfile = ProfileManager.getLastUsedRegularProfile();
if (sLargeIconBridge == null && mTab != null && mProfile != null) {
sLargeIconBridge = new LargeIconBridge(mProfile);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
import org.chromium.base.ContextUtils;
import org.chromium.base.Log;
import org.chromium.chrome.R;
import org.chromium.chrome.browser.profiles.Profile;
import org.chromium.chrome.browser.profiles.ProfileManager;

import java.util.ArrayList;
import java.util.Arrays;
Expand Down Expand Up @@ -145,7 +145,7 @@ public void onStopTrackingTouch(Slider slider) {
adsValue));
}
if (BraveAdsNativeHelper.nativeIsOptedInToNotificationAds(
Profile.getLastUsedRegularProfile())) {
ProfileManager.getLastUsedRegularProfile())) {
BraveRewardsNativeWorker.getInstance()
.setAdsPerHour((int) slider.getValue());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at https://mozilla.org/MPL/2.0/. */

package org.chromium.components.browser_ui.accessibility;
package org.chromium.chrome.browser.accessibility.settings;

import android.os.Bundle;

Expand Down
Loading

0 comments on commit 93e63c4

Please sign in to comment.