This reverts previous commit:
[Android] Filter warning after bytecode pacthing
With new R8 library there is a warning related to our bytecode patching:
Warning: Missing method void Lg2.d() (referenced from: void Vf2.run())
Without obfuscation it looks like this:
Warning: Missing method void org.chromium.chrome.browser.toolbar.ToolbarManager.$invoke$special$updateButtonStatus() (referenced from: void org.chromium.chrome.browser.toolbar.ToolbarManager$$ExternalSyntheticLambda3.run())
We do change invoke special to invoke virtual for this method and this is expected.
Chromium change:
chromium/chromium@e3db48a
Android: Stop disabling R8's allowaccessmodification -keep semantics
Causes a 5.5kb regression, but brings us closer to stock R8, and will
ensure visibility of test @rule fields are not changed, thus avoiding
bugs like bug 1265431.
Bug: 1265431
Additionaly fixed:
- c-tor signatures for various classes
- explicitly added header for network::ResourceRequest
Chromuim change:
https://chromium.googlesource.com/chromium/src/+/2c6cbee37831bffa83494c98eca09a8ca9def489
Modularize toolbar/
Moves the files in chrome/browser/toolbar (except some glue code) and
related resources to chrome/browser/ui/android/toolbar.
Bug: 1127732
Chromium change:
https://chromium.googlesource.com/chromium/src/+/4a6f627495111794c56c46873349521bcc9b5b22
Toolbar: Remove deps on chrome/browser/omaha
This CL applies some refactoring around toolbar/omaha in preparation
for toolbar modularization:
- Moves menu button/ui/item state definitions from
c.b.omaha.UpdateMenuItemHelper to toolbar/menu_button
- Inject MenuButtonState supplier to MenuButton MVC instead of
the components calling UpdateMenuItemHelper directly
Bug: 1127732
Chromium change:
https://chromium.googlesource.com/chromium/src/+/c84e15f86da8a6f00920d4dd03087cc88b8970f5
More feed launch reliability logging
* Log the "feed reloading" start event
* Log a catch-all launch end event when the stream is unbound: more specific feed launch end conditions (user navigated away, switched tabs/apps, etc.) will be added in another CL
* Use no-op logger in public builds or if reliability logging is disabled
Bug: 1195940
Stack layout in not taken into consideration in Chromium anymore and
unintendedly was broken by the following change:
https://chromium.googlesource.com/chromium/src/+/dc3038ca3e29694ab91dfc1832ff7b337489fcfa
Fix tab switcher button not working in a11y mode
This patch is a temporary fix while grid tab switcher is in the process
of being launched. Previously, accessibility mode was one of the cases
where the grid was not created. This poses a problem since the a11y
mode can change without the activity restarting. This patch removes the
a11y check for creating the grid and adds a special case to the
overview showing logic in ChromeTabbedActivity to handle this.
Bug: 1200727
Chromium change:
https://chromium.googlesource.com/chromium/src/+/2336b6557478c544a81650258aab4b0e7af49c78
Toolbar: Move BottomControls to modularized target
This CL moves the classes for BottomControls MVC component plus
its layout xml to chrome/browser/ui/android/toolbar/.
Following dependencies on chrome_java were removed:
- ShareDelegate - was not in use.
- TabGroupUi - split to BottomControlsContentDelegate and extend
from it.
Bug: 1127732
Chromium change:
https://chromium.googlesource.com/chromium/src/+/ea3ad04f98806c71fa5d7ed91faa1afeb1f61cd1
Remove search engine logo feature flag and cleanup surrounding code
- Simplified the logo/no-logo padding cases and removed associated
plumbing (mostly in LocationBarMediator/Phone).
- Simplified SearchEngineLogoUtils as the feature is enabled by default.
- Removed search engine logo feature flag.
- Move ReturnToChromeExperimentsUtil#isCanonicalizedNTPUrl to
UrlUtilities and generalize it a bit.
Bug: 1178959
Chromium change:
https://chromium.googlesource.com/chromium/src/+/8276a73257bad0497689dfb1edeb735be2b5c26b
Modularize most of //chrome/browser/notifications
Move the framework components of //chrome/browser/notifications out to a
module. This leaves behind web platform notification information and
notification scheduler files.
Presubmit is flagging in moved files (haven't changed lines), so skipping presubmit for this CL.
NOPRESUBMIT=true
Bug: 1174713
Chromium change:
https://chromium.googlesource.com/chromium/src/+/26eb7c14f9b19ae819bb7dc9a8d10e865a43fcc8
Android: Remove deps on chrome_java in c.b.search_engines
The package c.b.search_engines is used by several components in core
chrome. This CL removes its dependencies on chrome_java to pave
the way for the other components to be modularized easily.
Main dependencies handled are:
- SettingsLauncherImpl: Injected from ToolbarManager. This is
a stateless class so it can be shared/reused where the code
can be simplified.
- LocaleManager: Injects a runnable wrapping
LocaleManager#setSearchEngineAutoSwitch(false) to
SearchEngineAdapter
Bug: 1171512
Chromium change:
https://chromium.googlesource.com/chromium/src.git/+/00bfce0c7635650f36baa1b335aa17c72cde1e70
Fix a bug Chrome is showing 2 rows of most visited tiles when query tiles are enabled
On small screen device, only 1 row of most visited tile should show when
query tiles are enabled.
However, TileSection hard coded the number of rows to 2. So even though
Chrome reduced most visited tiles to 4, it could still end up showing in
2 rows if the screen can only accommodate 3 tiles in a row.
BUG=1166388
(cherry picked from commit e97d0ce51b15cdb72da9a0ae67d9ceac1d08f646)
Chromium change:
https://chromium.googlesource.com/chromium/src.git/+/2336b6557478c544a81650258aab4b0e7af49c78
commit 2336b6557478c544a81650258aab4b0e7af49c78
Author: Jinsuk Kim <jinsukkim@chromium.org>
Date: Mon Jan 11 01:13:17 2021 +0000
Toolbar: Move BottomControls to modularized target
This CL moves the classes for BottomControls MVC component plus
its layout xml to chrome/browser/ui/android/toolbar/.
Following dependencies on chrome_java were removed:
- ShareDelegate - was not in use.
- TabGroupUi - split to BottomControlsContentDelegate and extend
from it.
Bug: 1127732
Chromium change:
https://chromium.googlesource.com/chromium/src/+/eafd059d9f7f4656f7110349fa9ffd221dfae93c
Toolbar: TopUiThemeColorProvider
A ThemeColorProvider for top UI (TopUiThemeColorProvider)
replaces TabThemeColorProvider, and gets moved to a modularized
target chrome/browser/ui/android/theme. This is a new source of
truth for toolbar/top part of Chrome UI theme color.
Previously TabThemeColorHelper played the role, but now it was
redefined to provide the theme color coming from tab
contents only. TopUiThemeColorProvider puts together all
the signals and decides the final theme color to be used for
top UI.
Bug: 1127732
This prevents from build errors like
../../chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java:627:
error: incompatible types: Object cannot be converted to Profile
Profile profile = mTabModelProfileSupplier.get();