Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1449)

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java

Issue 1328743003: Update getColorStateList calls that were deprecated in M. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java b/chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java
index 3be0823a51b04cf5318915ffbd5ece4a8e3dd678..d8d789237fe2d71367319130ad29610b26a007dd 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/appmenu/AppMenuAdapter.java
@@ -19,6 +19,7 @@ import android.widget.ImageView;
import android.widget.ListView;
import android.widget.TextView;
+import org.chromium.base.ApiCompatibilityUtils;
import org.chromium.chrome.R;
import org.chromium.chrome.browser.widget.TintedImageButton;
import org.chromium.ui.base.LocalizationUtils;
@@ -253,7 +254,8 @@ class AppMenuAdapter extends BaseAdapter {
button.setImageDrawable(item.getIcon());
item.getIcon().setLevel(currentLevel);
if (item.isChecked()) {
- button.setTint(button.getResources().getColorStateList(R.color.blue_mode_tint));
+ button.setTint(ApiCompatibilityUtils.getColorStateList(
+ button.getResources(), R.color.blue_mode_tint));
}
button.setEnabled(item.isEnabled());
button.setFocusable(item.isEnabled());

Powered by Google App Engine
This is Rietveld 408576698