Update the bluetooth battery icon

In ag/2863892, we add a new parameter to tune the size of battery icon.
This cl use this parameter and update the icon in bluetooth detail page.

Bug: 65397557
Test: RunSettingsLibRoboTests & Screenshots
Change-Id: I6dd26f14b3209101dd39320b3720fbd4f79acf54
This commit is contained in:
jackqdyulei
2017-09-13 13:35:02 -07:00
parent 6361c9d851
commit 2c6a016b10
3 changed files with 27 additions and 14 deletions

View File

@@ -80,7 +80,7 @@ public class UtilsTest {
@Test
public void testGetBluetoothDrawable_noBatteryLevel_returnSimpleDrawable() {
final Drawable drawable = Utils.getBluetoothDrawable(RuntimeEnvironment.application,
R.drawable.ic_bt_laptop, BluetoothDevice.BATTERY_LEVEL_UNKNOWN);
R.drawable.ic_bt_laptop, BluetoothDevice.BATTERY_LEVEL_UNKNOWN, 1 /* iconScale */);
assertThat(drawable).isNotInstanceOf(BluetoothDeviceLayerDrawable.class);
}
@@ -88,7 +88,7 @@ public class UtilsTest {
@Test
public void testGetBluetoothDrawable_hasBatteryLevel_returnLayerDrawable() {
final Drawable drawable = Utils.getBluetoothDrawable(RuntimeEnvironment.application,
R.drawable.ic_bt_laptop, 10 /* batteryLevel */);
R.drawable.ic_bt_laptop, 10 /* batteryLevel */, 1 /* iconScale */);
assertThat(drawable).isInstanceOf(BluetoothDeviceLayerDrawable.class);
}