Files
brave-core/android/java
Artem Samoilenko a655f3b176 [cr147][Android] Replace TabContextMenuItemDelegate to ContextMenuItemDelegate
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/08483c4fea866719a9712db5d9a2d1ed531628f4

commit 08483c4fea866719a9712db5d9a2d1ed531628f4
Author: Hitarth Kothari <hitarthkothari@google.com>
Date:   Mon Feb 23 12:50:37 2026 -0800

    [ThinWebView] Add ThinWebViewContextMenuItemDelegate

    This CL adds context menu support for ThinWebView (used in the
    Preview/Ephemeral Tab) on Android.

    Key Changes:

    New Delegate: Implemented ThinWebViewContextMenuItemDelegate to handle
    actions like "Copy to clipboard" and "Open in default browser" for
    ThinWebView.

    New Menu Mode: Added ContextMenuMode.THIN_WEB_VIEW to
    ChromeContextMenuPopulator, providing a streamlined menu that excludes
    standard tab features (like "Read Later" or "Open in New Tab").

    Integration: Updated EphemeralTabCoordinator and ThinWebViewImpl to initialize and pass the context menu populator factory through the UI stack.

    ChromeContextMenuPopulatorTest to verify correct menu item filtering for the new mode.

    Testing: Added comprehensive unit tests in
    Bug: 483656137
    Change-Id: I4f293a21bd1a7eb74f90b2b06750aa7bb6473b67
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7572842
    Reviewed-by: Calder Kitagawa <ckitagawa@chromium.org>
    Auto-Submit: Hitarth Kothari <hitarthkothari@google.com>
    Reviewed-by: Jinsuk Kim <jinsukkim@chromium.org>
    Reviewed-by: Shakti Sahu <shaktisahu@chromium.org>
    Commit-Queue: Hitarth Kothari <hitarthkothari@google.com>
    Cr-Commit-Position: refs/heads/main@{#1588868}
2026-03-26 19:25:20 -04:00
..