Clean up tinted ImageView subclasses
* Introduce an ImageViewTinter that can be used by the TintedImageView
and the TintedImageButton classes. They're basically the same thing
already, but because Java doesn't support extending multiple classes
we're stuck in this hole.
* Introduce basic tests for the ImageViewTinter users.
* Make the AppMenuItemIcon a TintedImageButton so that it can be tinted
if needed. Also make it implement Checkable because that's basically
what it's already doing.
* The share icon was implemented in a different way than RDS. Make RDS
follow what the share icon does because it's probably easier to maintain
in the end, meaning that it now uses a AppMenuItemIcon.
* Make the RDS checkbox be tinted appropriately gray or blue to match the
top icon row. This is necessary because Android themeing is inconsistent
across KK and MM: the unchecked checkbox is straight black on KK but gray
on MM, while the checked checkbox is straight black on KK and blue on MM.
BUG=571445
Review-Url: https://codereview.chromium.org/2951133003
Cr-Commit-Position: refs/heads/master@{#482063}
diff --git a/chrome/android/java_sources.gni b/chrome/android/java_sources.gni
index a9bc2666..5cb4918 100644
--- a/chrome/android/java_sources.gni
+++ b/chrome/android/java_sources.gni
@@ -1231,6 +1231,7 @@
"java/src/org/chromium/chrome/browser/widget/FadingShadow.java",
"java/src/org/chromium/chrome/browser/widget/FadingShadowView.java",
"java/src/org/chromium/chrome/browser/widget/FloatLabelLayout.java",
+ "java/src/org/chromium/chrome/browser/widget/ImageViewTinter.java",
"java/src/org/chromium/chrome/browser/widget/LoadingView.java",
"java/src/org/chromium/chrome/browser/widget/MaterialProgressBar.java",
"java/src/org/chromium/chrome/browser/widget/NumberRollView.java",
@@ -1684,6 +1685,7 @@
"javatests/src/org/chromium/chrome/browser/webapps/WebappVisibilityTest.java",
"javatests/src/org/chromium/chrome/browser/webapps/WebApkIntegrationTest.java",
"javatests/src/org/chromium/chrome/browser/widget/DualControlLayoutTest.java",
+ "javatests/src/org/chromium/chrome/browser/widget/ImageViewTinterTest.java",
"javatests/src/org/chromium/chrome/browser/widget/OverviewListLayoutTest.java",
"javatests/src/org/chromium/chrome/browser/widget/PromoDialogTest.java",
"javatests/src/org/chromium/chrome/browser/widget/RadioButtonLayoutTest.java",