Chromium changes:
https://chromium.googlesource.com/chromium/src/+/a6364151203138d43e7f3b75faf5a1c0aefebafa
commit a6364151203138d43e7f3b75faf5a1c0aefebafa
Author: Mark Schillaci <mschillaci@google.com>
Date: Thu Oct 23 10:55:10 2025 -0700
[Bookmarks Bar] Make the default location the bookmark bar when visible
This CL updates the implementation of saving bookmarks in Clank so that
when the bookmark bar is visible, we save to the bar by default instead
of the Mobile Bookmarks folder, per specs.
With the CL, we update the BookmarkUtils class to save new bookmarks
to the bookmark bar when the bookmark bar is visible and the user has
not already selected a location, i.e. we are updating the default
location only from the "Mobile" to "Desktop" (i.e. bookmark bar)
folder. This change only applies to NORMAL type bookmarks, and not
other items such as reading list or price trackers.
We update the behavior of setting the last used parent (folder) to
no longer update when the default folder is used. We do this to account
for the case where a user bookmarks a page (which goes into Mobile
Bookmarks), then shows the bookmark bar, and bookmarks a new page. If
we save the location after the first bookmark event, then the next
event with the bookmark bar visible would not save to the bookmark bar.
We do want it to save to the bookmark bar though, because the user
didn't explicitly choose the default location the previous time. Once
the user picks a new location, then that location is used going forward.
We overload the method to add new bookmarks to include a boolean for the
bookmark bar visibility, and one that mimics the original without the
parameter. For instances where this is not relevant (e.g. adding a new
bookmark from the tab list), we will not use the bookmark bar visibility
check because the bar cannot be visible in that case.
Bug: 444468570
Change-Id: I691736736a269e889b00f512efac338dc69c4947
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7063535
Commit-Queue: Mark Schillaci <mschillaci@google.com>
Reviewed-by: Brandon Wylie <wylieb@google.com>
Reviewed-by: Wenyu Fu <wenyufu@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1534454}
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/023128ed40ef043a55ef085be41c92ba52f366ca
commit 023128ed40ef043a55ef085be41c92ba52f366ca
Author: Hidehiko Abe <hidehiko@chromium.org>
Date: Mon Oct 20 20:31:22 2025 -0700
Fix payment Add Card fragment "cancel" stack behavior.
Opening Add Card fragment wrongly wiped the fragment back stack.
This CL add a flag to keep the stack and put the fragment on top
of the stack. Then, add the flag on opening Add Card fragment.
BUG=452828634
TEST=Tryjob. On Dut, open "Paymen methods > Add payment method",
and made sure the detailed title behavior and the cancel button.
Change-Id: Ie5caefa814f54bb3a0430350852f3ce550fe2281
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7053182
Reviewed-by: Wenyu Fu <wenyufu@chromium.org>
Commit-Queue: Hidehiko Abe <hidehiko@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1532719}
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/01d95e61ef62d60b47ceb398266ad098f99589cd
commit 01d95e61ef62d60b47ceb398266ad098f99589cd
Author: Jinsuk Kim <jinsukkim@chromium.org>
Date: Thu Oct 16 18:20:54 2025 -0700
[mtb-cct] Add metrics for the effect of the delayed Message request
We were showing CPA over Message for Reader Mode by putting all the
Message display requests (ReaderModeManager #tryShowingPrompt) on hold
until we get a CPA display request (ReaderModeManager#
onContextualPageActionShown), only then decide what to do i.e.
if CPA will be shown then do not show Message, or if CPA button is
hidden, call #tryShowingPrompt again to display Message.
This caused Message UI to be displayed not when it was requested,
but some time later, at which point certain conditions might have
changed. We're interested in how often this delayed request can
fail due to the changes in the conditions in the meantime. This CL
adds a couple of histograms that let us know the stats.
Bug: 452029995
Change-Id: Id86478d15d7426ff53c05cf4a59214b08ac55bb2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7040031
Commit-Queue: Jinsuk Kim <jinsukkim@chromium.org>
Reviewed-by: Theresa Sullivan <twellington@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1531166}
Upstream is rolling out new `Bookmarks Bar` feature that is controlled from their `Appearance` settings.
So here we merge our `Appearance` settings with theirs to have all new features there with upstream's logic of when they are supposed to be available.
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/df2378696a4b27302afda4f38e1dad262896233c
commit df2378696a4b27302afda4f38e1dad262896233c
Author: Mark Schillaci <mschillaci@google.com>
Date: Fri Oct 3 12:21:53 2025 -0700
[Bookmarks Bar] Update field trial config
This CL updates the bookmarks bar field trial config to include Top
Controls Refactor and removes the standalone entry of the same.
Bug: N/A
Change-Id: I9c6b4b0eab4b32132e547457f52e3ed540eb355a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7008653
Reviewed-by: Theresa Sullivan <twellington@chromium.org>
Commit-Queue: Mark Schillaci <mschillaci@google.com>
Auto-Submit: Mark Schillaci <mschillaci@google.com>
Commit-Queue: Theresa Sullivan <twellington@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1524918}
Warning fixed:
../../brave/android/java/org/chromium/chrome/browser/password_manager/settings/PasswordSettings.java:290: Warning: Missing space between "fragment" on the previous line and "argument," here? Resulting string is "fragmentargument,". [TextConcatSpace]
+ "argument, but none was provided.";
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/cb981d31a11e2ad9d9d519e2d790e12e1fedfa3c
commit cb981d31a11e2ad9d9d519e2d790e12e1fedfa3c
Author: Masa Fujita <massan@google.com>
Date: Thu Oct 9 20:03:59 2025 -0700
flyout: a11y: Allow users to control flyout menus with keyboard
This CL adds the ability for the user to use the keyboard to control the
flyout menus.
When the user selects an item with arrow keys and decides to proceed,
the `View`'s click listeneris called. We capture this and run the flyout
logic when necessary.
This CL also makes it so that `ListMenuItemAdapter` sets up the view to
use both the delegate and the click listener upon click.
Bug: 447103380
Change-Id: I4560508cdfe63fab553e44478bb48d3ed528caca
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6978443
Reviewed-by: Peter Conn <peconn@chromium.org>
Reviewed-by: Ted Choc <tedchoc@chromium.org>
Reviewed-by: Jenna Himawan <jhimawan@google.com>
Commit-Queue: Masa Fujita <massan@google.com>
Cr-Commit-Position: refs/heads/main@{#1527899}
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/8e0ca53362ef330a49b98c7add3a7857fc82405e
commit 8e0ca53362ef330a49b98c7add3a7857fc82405e
Author: Martin Šrámek <msramek@chromium.org>
Date: Tue Oct 7 11:40:45 2025 -0700
Remove the kLinkedServicesSetting disabled code on Desktop and Android
Since the feature has been launched.
Apart from removing many references to the feature, flag, and tests, we're also adapting the ManageSyncSettings code from the previous approach (where the old strings were set in the XML file and the new strings programmatically overwritten in the Java code) to one where the strings are simply set in the XML file.
We're not removing the equivalent codepaths on iOS, where it hasn't launched yet.
Bug: 343132001
Change-Id: I8b92689b67db9485e87dd99657a32f1601277553
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7006398
Reviewed-by: Rainhard Findling <rainhard@chromium.org>
Commit-Queue: Martin Šrámek <msramek@chromium.org>
Reviewed-by: Marc Treib <treib@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1526439}
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/e9da334545f4152c14f5e60b2209b89ae7f49d9b
commit e9da334545f4152c14f5e60b2209b89ae7f49d9b
Author: Xi Han <hanxi@google.com>
Date: Fri Oct 3 14:58:20 2025 -0700
[Theme] Refactor initialization of NtpCustomizationConfigManager.
In this CL, we split the initialization of NtpCustomizationConfigManager:
- For customized colors: move to maybeInitializeColorTheme() and it is
triggered when listener is added which can provide the current
Activity's context. This is because a colorId could return different
color value in light|dark modes.
- For customized images: initialization remains in the constructor.
This is a refactoring CL without any behaviour changes.
Bug: 423579377
Change-Id: I9852565c0d4042fa4f0a4970756823ad88e6dd10
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7003871
Reviewed-by: Xinyi Ji <xinyiji@chromium.org>
Commit-Queue: Xi Han <hanxi@chromium.org>
Reviewed-by: Wenyu Fu <wenyufu@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1525042}
Remove Android Super Referrals. The feature is no longer supported or
used, and this cleanup helps reduce unused code and simplify the overall
system as part of https://github.com/brave/brave-browser/issues/44403.
Resets the overflow main menu to the top every time is shown. Modifications are applied using bytecode manipulations as we needed to modify upstream class `AppMenuHandlerImpl`.
Here we remove the original interfaces and move them directly to the places they are used.
Interfaces are still genereric, replacing them to a specific interfaces should be done when these parts of code are touched.
In addition, in this PR were fixed presubmit warnings in the files that were touched.
Introduces a unified Wallet-fragment architecture that centralizes how Brave's Android wallet UI talks to WalletModel, manages pending transactions, and stays in sync with keyring state.
[Android] Adds kBraveFreshNtpAfterIdleExpirement experiment flag.
That commit adds the flag with parameters and a functionality
to use cached flags on Android.
Resolves: https://github.com/brave/brave-browser/issues/50567
Previously, the import/export icons were not correctly tinted when the
Android OS was set to dark mode.
To correct this, the icons no longer use a hard-coded fill colour and an
iconTint property is applied in order to leverage the built-in support
that Chromium has for automatically adjusting icons for light/dark mode.
The icons have also been replaced with the upload/download SVG paths
from the brave/leo repo.
Resolvesbrave/brave-browser#50232
Previously, we removed a call to bringChromeTabbedActivityToTheTop in
order to prevent closing the server country selection dialog.
However, this introduced a regression in that the enrollment screens
which depend on this call no longer close and the user would resultantly
have to back out of them.
Now, we conditionally invoke the call unless the activity is coming from
either the country selection or city selection dialog.
Unit tests have been added to verify the behaviour.
Resolvesbrave/brave-browser#50163
* [cr142] Fixed open Mobile bookmarks folder as home page
Resolves https://github.com/brave/brave-browser/issues/50294
Chromium change:
https://source.chromium.org/chromium/chromium/src/+/7e28ed8607fec26cac4ab4dbc6c43f46f14bfe7b
components/bookmark_codec: start writing sha256
Writepath changes: Start writing SHA256 alongside MD5. Readpath changes:
Read MD5 and optionally SHA256.
After a couple of milestones, intended change is to stop writing the md5
but continue reading both. A few milestones after that, stop reading
md5.
Include `EnableBookmarkCodecSHA256` in case this cl needs to be disabled
via go/finch-killswitch.
Enabled-by-default-reason: killswitch EnableBookmarkCodecSHA256
Bug: 426243026
Change-Id: Ie545e1a3563dc3add88408899a6704016276e901
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6710952
Previously in af14cfe912 we fixed the
server selection dialog and prevented dialog closure when the user
selects an option.
As a result, the city selection dialog also needed code added to ensure
that it updated when the user selected an option. This commit implements
that change in the same manner as the aforementioned one.
Resolvesbrave/brave-browser#50159
Occasionally, users have reported that the NTP (New Tab Page) background
image is partially cut-off after restarting the app.
It now appears likely that this is being caused by the call to
`removeOnGlobalLayoutListener(this)` which results in nothing happening
when the background image needs to be resized.
This commit deletes the line that unregisters the listener and instead
adds code that checks if the measured height/width of the background
image differs from the values in a previous run. If they are different,
we re-fetch the image. We delete the listener when the window goes
away instead.
Fixes DApp activity flags by making the status bar not translucent and optimizes the fragment container view. Tested also on the new Android API 35 where the status bar is
thicker.
Simplifies the wallet sign message UI by consolidating DAppsMessageFragment and SignMessagePagerAdapter into SignMessageFragment removing unnecessary abstraction layers.
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/c818a3850128c73f62537482e36f43367e9c40ce
commit c818a3850128c73f62537482e36f43367e9c40ce
Author: Tomasz Wiszkowski <ender@google.com>
Date: Fri Oct 3 15:11:19 2025 -0700
Ensure all StatusIcons meet the specific size constraint.
We've observed a weird behavior when toggling search engines results
in oversize and cropped search engine icon shown in the omnibox.
This is partially because the ChromeTransitionDrawable animating
between states receives Drawables of inconsistent sizes, and changes
its intrinsic size, trying to accommodate the larger of the drawables.
Second more important factor is that the StatusIconResource carrying
drawable was shared between two different views - the NTP Fakebox and
the Omnibox. One view altering the Drawable state made the other view
instantly see these alterations, resulting in wrong positioning of
the icon.
This change aligns all StatusView icon sizes, ensuring that no icon
can ever change the intrinsic size of the TransitionDrawable.
Change intentionally kept small as it will need to be cherrypicked.
Fixed: 449181250
Change-Id: I59953971b99a01d015aa2398db058677c7816d7c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7007583
Commit-Queue: Tomasz Wiszkowski <ender@google.com>
Reviewed-by: Patrick Noland <pnoland@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1525046}
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/a11ac5d97f40076f5d1502084c6ef8972cff2a22
commit a11ac5d97f40076f5d1502084c6ef8972cff2a22
Author: Samuel Huang <huangs@chromium.org>
Date: Thu Oct 2 12:00:50 2025 -0700
[MVT] Fix MVT container sizing and centering on Tablets.
By "blocks" we include MVT tiles and the "Add now" button.
On Tablets, blocks and its container have special behavior:
1. Depending on **initial** block count, these render in modes:
* Centered: With "few" blocks present: The container is WRAP_CONTENT,
and "edge margins" (outer margin of outer blocks) expanded so blocks
are centered and immobile.
* Overflowed: With "many" blocks present: The container is
MATCH_PARENT, and "edge margins" are assigned a fixed value. The
blocks become scrollable.
2. When changing from "many" blocks to "few" blocks, the Overflowed
state remains. In this case, blocks no longer scroll, and are start-
aligned instead of centered.
(2) was intentional, presumably to reduce tiles "jumping" on repeated
tile removal. NewTabPageLayout (for container) and TilesLinearLayout
(for "edge margins") implemented this by doing the following:
* Store initial tile count and block count.
* Use these counts and width constants to compute "content width".
* If "content width" <= "container" size then Centered (AKA "full
filled", "all filled"); else Overflowed.
Now, MVT on tablets has some longstanding oddities
O1. When Centered, the container might not reach full width.
O2. Container may shrink on repeated tile removal (and centered) --
this is a cross between Centered (re. WRAP_CONTENT) and Overflowed
(re. fixed "edge margin") modes.
O3. When changing from "few" blocks to "many" blocks (by adding Custom
Tiles), Overflow mode does kick in sometimes, leading to blocks
appearing off-screen but cannot be scrolled to.
This CL fixes the oddities and removes behavior (2); now Centered and
Overflowed behavior depends on **current** (instead of the initial)
block count -- this fixes (O3). High level changes:
* Stop storing initial tile and block counts.
* Centralize Centered / Overflowed decision, including "content width"
computation, to MostVisitedTilesLayout.
* Change MVT child addition semantics from {Tile, non-Tile} to
{Tile, Divider, UI View (for the "Add new" button)}.
Bugs that were found and fixed:
* The duplicated Centered / Overflowed decision logic were inconsistent;
the NewTabPageLayout version (for WRAP_CONTENT / MATCH_PARENT) didn't
account for Custom Tile changes, i.e., divider & "Add new" button.
This led to (O2), and is fixed when we dedup the logic.
* When "divider gap" was changed to same as "tile gap" in
crrev.com/c/6780677 , we didn't update "content width" calculation.
This also led to (O2), and is fixed by having dividers not contribute
to "content width".
* Resources.getDimension() returns (float) PX value, and NOT DP. The
misunderstanding led to explicit conversions that made the width of
the "Add new" too large (TileRenderer.renderTileSection()). This led
to (O1). Fixing this also simplified code.
Bug: 447086773, 388782412
Change-Id: Id1400e672f1f0be11b4cc218cd20521988c3455f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7004884
Commit-Queue: Samuel Huang <huangs@chromium.org>
Reviewed-by: Calder Kitagawa <ckitagawa@chromium.org>
Reviewed-by: Xi Han <hanxi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1524365}
InflateException happened while inflating Buttons with style
`?android:attr/buttonBarButtonStyle`. Changed to `@style/TextButton`.
Visually looks the same as on Nightly cr140.
Chromium change: unclear