Chromium change:
https://chromium.googlesource.com/chromium/src.git/+/afd16b5973b054f53733695ce33708ef430a0b83
Toolbar: Remove deps on TrackerFactory
Removes deps on TrackerFactory in ToolbarTabControllerImpl and
move it to the modularized toolbar/. There are a few more classes
that can also be moved:
ToolbarTabControllerImplTest.java
ToolbarTabControllerImpl.java
top/IncognitoSwitchCoordinator.java
top/IncognitoSwitchProperties.java
top/IncognitoSwitchViewBinder.java
top/TabSwitcherActionMenuCoordinator.java
top/TabSwitcherActionMenuRenderTest.java
Bug: 1127732
Fixes this lint error:
../../chrome/android/java/res/layout/brave_sync_done.xml:85: Error: Must use app:tint instead of android:tint [UseAppTint]
android:tint="@android:color/black" />
Fixes these java warnings:
../../brave/android/java/org/chromium/chrome/browser/custom_layout/popup_window_tooltip/PopupWindowTooltip.java:66: warning: [NoRedundantFieldInit] Do not explicitly initialize a non-final field with a default value
private boolean dismissed = false;
^
(see https://issuetracker.google.com/issues/37124982)
Did you mean 'private boolean dismissed;'?
../../brave/android/java/org/chromium/chrome/browser/custom_layout/popup_window_tooltip/PopupWindowTooltip.java:302: warning: [MultiVariableDeclaration] Variable declarations should declare only one variable
float x, y;
^
(see https://google.github.io/styleguide/javaguide.html#s4.8.2.1-variables-per-declaration)
Did you mean 'float x;float y;'?
../../brave/android/java/org/chromium/chrome/browser/custom_layout/popup_window_tooltip/PopupWindowTooltip.java:370: warning: [NoRedundantFieldInit] Do not explicitly initialize a non-final field with a default value
private boolean modal = false;
^
(see https://issuetracker.google.com/issues/37124982)
Did you mean 'private boolean modal;'?
../../brave/android/java/org/chromium/chrome/browser/custom_layout/popup_window_tooltip/ArrowColorDrawable.java:21: warning: [MultiVariableDeclaration] Variable declarations should declare only one variable
public static final int LEFT = 0, TOP = 1, RIGHT = 2, BOTTOM = 3, AUTO = 4;
^
(see https://google.github.io/styleguide/javaguide.html#s4.8.2.1-variables-per-declaration)
Did you mean 'public static final int LEFT = 0;public static final int TOP = 1;public static final int RIGHT = 2;public static final int BOTTOM = 3;public static final int AUTO = 4;'?
../../brave/android/java/org/chromium/chrome/browser/custom_layout/popup_window_tooltip/ArrowColorDrawable.java:85: warning: [MissingOverride] setColor overrides method in ColorDrawable; expected @Override
public void setColor(@ColorInt int color) {
^
(see https://errorprone.info/bugpattern/MissingOverride)
Did you mean '@Override public void setColor(@ColorInt int color) {'?
Fixes errors like
../../chrome/android/java/res/layout/binance_deposit_layout.xml:39: Error: Must use app:tint instead of android:tint [UseAppTint]
android:tint="@android:color/white"
Chromium change:
https://chromium.googlesource.com/chromium/src/+/33026f0b97add89f468693c385db94d821e55b6e
Android: Enable custom lint checks from aars (reland)
Some aar files (e.g. androidx) that chrome depends on contain a lint.jar
file and/or a annotations.zip file. The lint.jar file includes custom
android lint checks. The annotations.zip file contains @IntDef and other
annotations needed for lint checks that are usually available by source
but are not available in aars.
By using these files, we can make our existing lint checks more
comprehensive as well as benefit from lint checks by the aar library
authors.
See newly ignored checks in lint-baseline.xml which is updated in this
CL as an example. Actually fixing these errors is left for future CLs
in order to enable them quicker and avoid unnecessary relands.
Original CL: https://crrev.com/c/2510793
Fixed:
- Avoid ../../ prefix in temporary extraction of aar files.
Tbr: Reland with trivial fix.
Bug: 1078229
Chromium change:
https://chromium.googlesource.com/chromium/src/+/88757c64b874d89657ba1e2a4c53120d17fc84ff
Toolbar: HomeButton without HomepageManager dependency
Made HomeButton work without dependency on chrome.browser.homepage
classes. All the deps are now deferred to ToolbarManager.
The dependencies are injected not through ctor but init method
introduced in this CL since the home button and the enclosing view
(ToolbarLayout) are instantiated from xml.
Menu handling logic was moved to HomepageManager to make it test-
friendly.
Also removed a bunch of dead code in HomeButton. Several public setters
(ActivityTabObserver, ThemeColorProvider, StartSurfaceSupplier) were
used by BrowsingModeBottomToolbarCoordinator only (see
https://crrev.com/c/1981099). There's no callsite left any more as
the class was already gone.
Bug: 1127732
Chromium change:
https://chromium.googlesource.com/chromium/src/+/88757c64b874d89657ba1e2a4c53120d17fc84ff
Toolbar: HomeButton without HomepageManager dependency
Made HomeButton work without dependency on chrome.browser.homepage
classes. All the deps are now deferred to ToolbarManager.
The dependencies are injected not through ctor but init method
introduced in this CL since the home button and the enclosing view
(ToolbarLayout) are instantiated from xml.
Menu handling logic was moved to HomepageManager to make it test-
friendly.
Also removed a bunch of dead code in HomeButton. Several public setters
(ActivityTabObserver, ThemeColorProvider, StartSurfaceSupplier) were
used by BrowsingModeBottomToolbarCoordinator only (see
https://crrev.com/c/1981099). There's no callsite left any more as
the class was already gone.
Bug: 1127732