[ThemeSync] Add pre-defined theme collection options. [chromium/src : main]

0 views
Skip to first unread message

Xi Han (Gerrit)

unread,
Jul 24, 2026, 5:33:08 PM (11 hours ago) Jul 24
to Xinyi Ji, android-bu...@system.gserviceaccount.com, Chromium LUCI CQ, chromium...@chromium.org, hanxi...@chromium.org
Attention needed from Xinyi Ji

Xi Han added 1 comment

Patchset-level comments
File-level comment, Patchset 9 (Latest):
Xi Han . resolved

Hi Xinyi,
PTAL, thanks!

Open in Gerrit

Related details

Attention is currently required from:
  • Xinyi Ji
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: If21e27a6a672886f0f7f6c8345e7266413e1252c
Gerrit-Change-Number: 8126275
Gerrit-PatchSet: 9
Gerrit-Owner: Xi Han <ha...@chromium.org>
Gerrit-Reviewer: Xi Han <ha...@chromium.org>
Gerrit-Reviewer: Xinyi Ji <xin...@chromium.org>
Gerrit-Attention: Xinyi Ji <xin...@chromium.org>
Gerrit-Comment-Date: Fri, 24 Jul 2026 21:32:57 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Xinyi Ji (Gerrit)

unread,
Jul 24, 2026, 8:40:47 PM (8 hours ago) Jul 24
to Xi Han, android-bu...@system.gserviceaccount.com, Chromium LUCI CQ, chromium...@chromium.org, hanxi...@chromium.org
Attention needed from Xi Han

Xinyi Ji voted Code-Review+1

Code-Review+1
Open in Gerrit

Related details

Attention is currently required from:
  • Xi Han
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: If21e27a6a672886f0f7f6c8345e7266413e1252c
    Gerrit-Change-Number: 8126275
    Gerrit-PatchSet: 9
    Gerrit-Owner: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Xinyi Ji <xin...@chromium.org>
    Gerrit-Attention: Xi Han <ha...@chromium.org>
    Gerrit-Comment-Date: Sat, 25 Jul 2026 00:40:38 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    open
    diffy

    Xinyi Ji (Gerrit)

    unread,
    Jul 24, 2026, 8:41:04 PM (8 hours ago) Jul 24
    to Xi Han, android-bu...@system.gserviceaccount.com, Chromium LUCI CQ, chromium...@chromium.org, hanxi...@chromium.org
    Attention needed from Xi Han

    Xinyi Ji added 1 comment

    Patchset-level comments
    Xinyi Ji . resolved

    LGTM! 😊

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Xi Han
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: If21e27a6a672886f0f7f6c8345e7266413e1252c
    Gerrit-Change-Number: 8126275
    Gerrit-PatchSet: 9
    Gerrit-Owner: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Xinyi Ji <xin...@chromium.org>
    Gerrit-Attention: Xi Han <ha...@chromium.org>
    Gerrit-Comment-Date: Sat, 25 Jul 2026 00:40:54 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    satisfied_requirement
    open
    diffy

    Xi Han (Gerrit)

    unread,
    Jul 24, 2026, 9:49:42 PM (6 hours ago) Jul 24
    to Xinyi Ji, android-bu...@system.gserviceaccount.com, Chromium LUCI CQ, chromium...@chromium.org, hanxi...@chromium.org

    Xi Han voted Commit-Queue+2

    Commit-Queue+2
    Open in Gerrit

    Related details

    Attention set is empty
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: If21e27a6a672886f0f7f6c8345e7266413e1252c
    Gerrit-Change-Number: 8126275
    Gerrit-PatchSet: 9
    Gerrit-Owner: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Xinyi Ji <xin...@chromium.org>
    Gerrit-Comment-Date: Sat, 25 Jul 2026 01:49:30 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    open
    diffy

    Chromium LUCI CQ (Gerrit)

    unread,
    Jul 24, 2026, 9:53:00 PM (6 hours ago) Jul 24
    to Xi Han, Xinyi Ji, android-bu...@system.gserviceaccount.com, chromium...@chromium.org, hanxi...@chromium.org

    Chromium LUCI CQ submitted the change

    Change information

    Commit message:
    [ThemeSync] Add pre-defined theme collection options.

    In this CL, we allow to add at most 2 pre-defined theme collection
    images when the options in the history list is less than 6.
    1. The history list will show: default + local history + remote
    history + pre-defined options (2 chrome colors + 2 theme
    collections);
    2. In NtpThemeSyncHistoryCoordinator, we fetch URLs from the theme
    collection id0 and filter out any URLs already exist in local
    history to prevent duplicated entries;
    3. For pre-defined theme collection images, we fetch its preview image
    and show it in the recyclerview. The preview image is saved in
    NtpBackgroundDataImageBase.
    4. After the user the user clicks a pre-defined theme collection item,
    fetch its background bitmap. After the bitmap is ready, we will pick
    the primary color based on the preview bitmap, and save the data to
    the local history of the shared preference. This is different from
    a regular theme collection data, the saving data is done when the
    bottom sheet is closed. If user clicks it again, we reused the
    fetched bitmap.
    5. Resolve an image missing issue when clicking multiple options from
    the history list. This is because the newly selected items will be
    persistent to the shared preference, and the bitmap of the removed
    entry will be deleted as at most 3 items are kept in local history.
    To fix it, any time when a item (originally from the local history)
    is clicked, we save its bitmap to disk in case it has been deleted
    before. We don't update the history list when it is showing.
    6. Fix the issue that recyclerview's scroll position is reset after
    clicking an item at the end by returning the history recyclerview
    in NtpCustomizationBottomSheetContent.
    Demo: http://shortn/_AEeTlThxRE.
    Bug: 488439751
    Change-Id: If21e27a6a672886f0f7f6c8345e7266413e1252c
    Commit-Queue: Xi Han <ha...@chromium.org>
    Reviewed-by: Xinyi Ji <xin...@chromium.org>
    Cr-Commit-Position: refs/heads/main@{#1668241}
    Files:
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/NtpCustomizationBottomSheetContent.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/NtpCustomizationCoordinator.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/NtpCustomizationUtils.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/theme/theme_collections/NtpThemeCollectionManager.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/theme_sync/NtpThemeSyncHistoryCoordinator.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/theme_sync/NtpThemeSyncHistoryRecyclerViewAdaptor.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/theme_sync/data/NtpBackgroundDataImageBase.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/theme_sync/data/NtpBackgroundDataManager.java
    • M chrome/browser/ntp_customization/java/src/org/chromium/chrome/browser/ntp_customization/theme_sync/data/NtpBackgroundDataThemeCollection.java
    • M chrome/browser/ntp_customization/junit/src/org/chromium/chrome/browser/ntp_customization/NtpCustomizationBottomSheetContentUnitTest.java
    • M chrome/browser/ntp_customization/junit/src/org/chromium/chrome/browser/ntp_customization/theme_sync/NtpThemeSyncHistoryCoordinatorUnitTest.java
    • M chrome/browser/ntp_customization/junit/src/org/chromium/chrome/browser/ntp_customization/theme_sync/NtpThemeSyncHistoryRecyclerViewAdaptorUnitTest.java
    Change size: XL
    Delta: 12 files changed, 966 insertions(+), 120 deletions(-)
    Branch: refs/heads/main
    Submit Requirements:
    • requirement satisfiedCode-Review: +1 by Xinyi Ji
    Open in Gerrit
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: merged
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: If21e27a6a672886f0f7f6c8345e7266413e1252c
    Gerrit-Change-Number: 8126275
    Gerrit-PatchSet: 10
    Gerrit-Owner: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
    Gerrit-Reviewer: Xi Han <ha...@chromium.org>
    Gerrit-Reviewer: Xinyi Ji <xin...@chromium.org>
    open
    diffy
    satisfied_requirement

    luci-bisection@appspot.gserviceaccount.com (Gerrit)

    unread,
    2:13 AM (2 hours ago) 2:13 AM
    to Chromium LUCI CQ, Xi Han, Xinyi Ji, android-bu...@system.gserviceaccount.com, chromium...@chromium.org, hanxi...@chromium.org

    Related details

    Attention set is empty
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: revert
    satisfied_requirement
    open
    diffy
    Reply all
    Reply to author
    Forward
    0 new messages