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

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

Issue 2813703004: chooser: Don't call mutate on new drawable (Closed)
Patch Set: Address tedchoc's comments Created 3 years, 8 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
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/ItemChooserDialog.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/BluetoothChooserDialog.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/BluetoothChooserDialog.java b/chrome/android/java/src/org/chromium/chrome/browser/BluetoothChooserDialog.java
index d4b0236a4efd2a632a88ee9c17ed0c55bbd43959..13b491ae759cf2d9710fb10a694b6714954c3586 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/BluetoothChooserDialog.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/BluetoothChooserDialog.java
@@ -372,17 +372,12 @@ public class BluetoothChooserDialog
}
@VisibleForTesting
- Drawable getConnectedIcon() {
- return mConnectedIcon.getConstantState().newDrawable().mutate();
- }
-
- @VisibleForTesting
@CalledByNative
void addOrUpdateDevice(String deviceId, String deviceName, boolean isGATTConnected) {
Drawable icon = null;
String iconDescription = null;
if (isGATTConnected) {
- icon = getConnectedIcon();
+ icon = mConnectedIcon.getConstantState().newDrawable();
iconDescription = mConnectedIconDescription;
}
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/ItemChooserDialog.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698