Move SettingsLib icons to android.

Bug: 122263617
Test: make
Change-Id: I11ce02f3f65f429fd4375a5522c060c8080f4813
This commit is contained in:
Amin Shaikh
2019-01-24 17:59:49 -05:00
parent dbff07d1b1
commit 10f363bb18
56 changed files with 80 additions and 177 deletions

View File

@@ -1423,6 +1423,27 @@
<java-symbol type="drawable" name="ic_sim_card_multi_48px_clr" />
<java-symbol type="drawable" name="ic_signal_cellular_alt_24px" />
<java-symbol type="drawable" name="btn_borderless_rect" />
<java-symbol type="drawable" name="ic_bt_cellphone" />
<java-symbol type="drawable" name="ic_bt_headphones_a2dp" />
<java-symbol type="drawable" name="ic_bt_headset_hfp" />
<java-symbol type="drawable" name="ic_bt_hearing_aid" />
<java-symbol type="drawable" name="ic_bt_laptop" />
<java-symbol type="drawable" name="ic_bt_misc_hid" />
<java-symbol type="drawable" name="ic_bt_network_pan" />
<java-symbol type="drawable" name="ic_bt_pointing_hid" />
<java-symbol type="drawable" name="ic_expand_more" />
<java-symbol type="drawable" name="ic_lockscreen_ime" />
<java-symbol type="drawable" name="ic_menu" />
<java-symbol type="drawable" name="ic_minus" />
<java-symbol type="drawable" name="ic_mode_edit" />
<java-symbol type="drawable" name="ic_plus" />
<java-symbol type="drawable" name="ic_qs_night_display_on" />
<java-symbol type="drawable" name="ic_settings_bluetooth" />
<java-symbol type="drawable" name="ic_settings_print" />
<java-symbol type="drawable" name="ic_signal_location" />
<java-symbol type="drawable" name="ic_info_outline_24" />
<java-symbol type="drawable" name="stat_notify_mmcc_indication_icn" />
<java-symbol type="drawable" name="autofilled_highlight"/>
<java-symbol type="drawable" name="ic_camera" />

View File

@@ -23,6 +23,7 @@ import android.view.MotionEvent;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.InputMethodManager;
import com.android.printspooler.R;
/**
@@ -366,7 +367,8 @@ public final class PrintContentView extends ViewGroup implements View.OnClickLis
// and is janky. Now it is there but transparent, doing nothing.
mEmbeddedContentScrim.setOnClickListener(null);
mEmbeddedContentScrim.setClickable(false);
mExpandCollapseIcon.setBackgroundResource(R.drawable.ic_expand_more);
mExpandCollapseIcon.setBackgroundResource(
com.android.internal.R.drawable.ic_expand_more);
} else {
if (mMoreOptionsButton.getVisibility() != View.GONE) {
mMoreOptionsButton.setVisibility(View.VISIBLE);

View File

@@ -1,32 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2016 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24.0"
android:viewportHeight="24.0"
android:tint="?android:attr/textColorSecondary">
<path
android:fillColor="#FF000000"
android:pathData="M11,7h2v2h-2z"/>
<path
android:fillColor="#FF000000"
android:pathData="M11,11h2v6h-2z"/>
<path
android:fillColor="#FF000000"
android:pathData="M12,2C6.48,2 2,6.48 2,12c0,5.52 4.48,10 10,10s10,-4.48 10,-10C22,6.48 17.52,2 12,2zM12,20c-4.41,0 -8,-3.59 -8,-8c0,-4.41 3.59,-8 8,-8s8,3.59 8,8C20,16.41 16.41,20 12,20z"/>
</vector>

View File

@@ -1,28 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2017 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<vector
xmlns:android="http://schemas.android.com/apk/res/android"
android:name="ic_rotate_to_landscape"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24.0"
android:viewportWidth="24.0"
android:tint="?android:attr/colorControlNormal" >
<path
android:fillColor="#FF000000"
android:pathData="M12.72,23H11C5.49,23 1,18.51 1,13h2c0,3.78 2.63,6.95 6.15,7.79L8.13,19L9.87,18L12.72,23zM13,1h-1.72l2.85,5L15.87,5l-1.02,-1.79C18.37,4.05 21,7.22 21,11h2C23,5.49 18.51,1 13,1zM10.23,6L18,13.76L13.77,18L6,10.24L10.23,6C10.23,6 10.23,6 10.23,6M10.23,4C9.72,4 9.21,4.2 8.82,4.59L4.59,8.82c-0.78,0.78 -0.78,2.04 0,2.82l7.77,7.77c0.39,0.39 0.9,0.59 1.41,0.59c0.51,0 1.02,-0.2 1.41,-0.59l4.24,-4.24c0.78,-0.78 0.78,-2.04 0,-2.82l-7.77,-7.77C11.26,4.2 10.75,4 10.23,4L10.23,4z"/>
</vector>

View File

@@ -1,27 +0,0 @@
<!--
Copyright (C) 2016 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24.0"
android:viewportHeight="24.0">
<path
android:fillColor="#FFFFFFFF"
android:pathData="M10.8,12.7l2.4,0l-1.2,-3.7z"/>
<path
android:fillColor="#FF000000"
android:pathData="M12,2C6.5,2 2,6.5 2,12s4.5,10 10,10s10,-4.5 10,-10S17.5,2 12,2zM14.3,16l-0.7,-2h-3.2l-0.7,2H7.8L11,7h2l3.2,9H14.3z"/>
</vector>

View File

@@ -67,7 +67,7 @@
android:layout_toStartOf="@android:id/button2"
android:contentDescription="@string/accessibility_manual_zen_less_time"
android:tint="?android:attr/colorAccent"
android:src="@drawable/ic_minus" />
android:src="@*android:drawable/ic_minus" />
<ImageView
android:id="@android:id/button2"
@@ -79,6 +79,6 @@
android:layout_centerVertical="true"
android:contentDescription="@string/accessibility_manual_zen_more_time"
android:tint="?android:attr/colorAccent"
android:src="@drawable/ic_plus" />
android:src="@*android:drawable/ic_plus" />
</RelativeLayout>
</RelativeLayout>

View File

@@ -24,7 +24,7 @@
<style name="BorderlessButton">
<item name="android:padding">12dp</item>
<item name="android:background">@drawable/btn_borderless_rect</item>
<item name="android:background">@*android:drawable/btn_borderless_rect</item>
<item name="android:gravity">center</item>
</style>
</resources>

View File

@@ -296,7 +296,7 @@ public class A2dpProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_headphones_a2dp;
return com.android.internal.R.drawable.ic_bt_headphones_a2dp;
}
protected void finalize() {

View File

@@ -205,7 +205,7 @@ final class A2dpSinkProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_headphones_a2dp;
return com.android.internal.R.drawable.ic_bt_headphones_a2dp;
}
protected void finalize() {

View File

@@ -61,13 +61,14 @@ public class BluetoothUtils {
if (btClass != null) {
switch (btClass.getMajorDeviceClass()) {
case BluetoothClass.Device.Major.COMPUTER:
return new Pair<>(getBluetoothDrawable(context, R.drawable.ic_bt_laptop, level,
iconScale),
return new Pair<>(getBluetoothDrawable(context,
com.android.internal.R.drawable.ic_bt_laptop, level, iconScale),
context.getString(R.string.bluetooth_talkback_computer));
case BluetoothClass.Device.Major.PHONE:
return new Pair<>(
getBluetoothDrawable(context, R.drawable.ic_bt_cellphone, level,
getBluetoothDrawable(context,
com.android.internal.R.drawable.ic_bt_cellphone, level,
iconScale),
context.getString(R.string.bluetooth_talkback_phone));
@@ -79,7 +80,8 @@ public class BluetoothUtils {
case BluetoothClass.Device.Major.IMAGING:
return new Pair<>(
getBluetoothDrawable(context, R.drawable.ic_settings_print, level,
getBluetoothDrawable(context,
com.android.internal.R.drawable.ic_settings_print, level,
iconScale),
context.getString(R.string.bluetooth_talkback_imaging));
@@ -98,19 +100,22 @@ public class BluetoothUtils {
if (btClass != null) {
if (btClass.doesClassMatch(BluetoothClass.PROFILE_HEADSET)) {
return new Pair<>(
getBluetoothDrawable(context, R.drawable.ic_bt_headset_hfp, level,
getBluetoothDrawable(context,
com.android.internal.R.drawable.ic_bt_headset_hfp, level,
iconScale),
context.getString(R.string.bluetooth_talkback_headset));
}
if (btClass.doesClassMatch(BluetoothClass.PROFILE_A2DP)) {
return new Pair<>(
getBluetoothDrawable(context, R.drawable.ic_bt_headphones_a2dp, level,
getBluetoothDrawable(context,
com.android.internal.R.drawable.ic_bt_headphones_a2dp, level,
iconScale),
context.getString(R.string.bluetooth_talkback_headphone));
}
}
return new Pair<>(
getBluetoothDrawable(context, R.drawable.ic_settings_bluetooth, level, iconScale),
getBluetoothDrawable(context,
com.android.internal.R.drawable.ic_settings_bluetooth, level, iconScale),
context.getString(R.string.bluetooth_talkback_bluetooth));
}

View File

@@ -226,7 +226,7 @@ public class HeadsetProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_headset_hfp;
return com.android.internal.R.drawable.ic_bt_headset_hfp;
}
protected void finalize() {

View File

@@ -228,7 +228,7 @@ public class HearingAidProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_hearing_aid;
return com.android.internal.R.drawable.ic_bt_hearing_aid;
}
protected void finalize() {

View File

@@ -211,7 +211,7 @@ final class HfpClientProfile implements LocalBluetoothProfile {
@Override
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_headset_hfp;
return com.android.internal.R.drawable.ic_bt_headset_hfp;
}
protected void finalize() {

View File

@@ -171,7 +171,7 @@ public class HidDeviceProfile implements LocalBluetoothProfile {
@Override
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_misc_hid;
return com.android.internal.R.drawable.ic_bt_misc_hid;
}
protected void finalize() {

View File

@@ -165,7 +165,7 @@ public class HidProfile implements LocalBluetoothProfile {
public int getDrawableResource(BluetoothClass btClass) {
if (btClass == null) {
return R.drawable.ic_lockscreen_ime;
return com.android.internal.R.drawable.ic_lockscreen_ime;
}
return getHidClassDrawable(btClass);
}
@@ -174,11 +174,11 @@ public class HidProfile implements LocalBluetoothProfile {
switch (btClass.getDeviceClass()) {
case BluetoothClass.Device.PERIPHERAL_KEYBOARD:
case BluetoothClass.Device.PERIPHERAL_KEYBOARD_POINTING:
return R.drawable.ic_lockscreen_ime;
return com.android.internal.R.drawable.ic_lockscreen_ime;
case BluetoothClass.Device.PERIPHERAL_POINTING:
return R.drawable.ic_bt_pointing_hid;
return com.android.internal.R.drawable.ic_bt_pointing_hid;
default:
return R.drawable.ic_bt_misc_hid;
return com.android.internal.R.drawable.ic_bt_misc_hid;
}
}

View File

@@ -200,7 +200,7 @@ public final class MapClientProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_cellphone;
return com.android.internal.R.drawable.ic_bt_cellphone;
}
protected void finalize() {

View File

@@ -196,7 +196,7 @@ public class MapProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_cellphone;
return com.android.internal.R.drawable.ic_bt_cellphone;
}
protected void finalize() {

View File

@@ -153,7 +153,7 @@ public class PanProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_network_pan;
return com.android.internal.R.drawable.ic_bt_network_pan;
}
// Tethering direction determines UI strings.

View File

@@ -192,7 +192,7 @@ public final class PbapClientProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_cellphone;
return com.android.internal.R.drawable.ic_bt_cellphone;
}
protected void finalize() {

View File

@@ -135,7 +135,7 @@ public class PbapServerProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_cellphone;
return com.android.internal.R.drawable.ic_bt_cellphone;
}
protected void finalize() {

View File

@@ -196,7 +196,7 @@ final class SapProfile implements LocalBluetoothProfile {
}
public int getDrawableResource(BluetoothClass btClass) {
return R.drawable.ic_bt_cellphone;
return com.android.internal.R.drawable.ic_bt_cellphone;
}
protected void finalize() {

View File

@@ -19,7 +19,6 @@ import android.bluetooth.BluetoothClass;
import android.content.Context;
import android.util.Log;
import com.android.settingslib.R;
import com.android.settingslib.bluetooth.CachedBluetoothDevice;
/**
@@ -45,7 +44,7 @@ public class BluetoothMediaDevice extends MediaDevice {
@Override
public int getIcon() {
//TODO(b/117129183): This is not final icon for bluetooth device, just for demo.
return R.drawable.ic_bt_headphones_a2dp;
return com.android.internal.R.drawable.ic_bt_headphones_a2dp;
}
@Override

View File

@@ -20,8 +20,6 @@ import android.widget.Toast;
import androidx.mediarouter.media.MediaRouter;
import com.android.settingslib.R;
/**
* InfoMediaDevice extends MediaDevice to represents wifi device.
*/
@@ -45,7 +43,7 @@ public class InfoMediaDevice extends MediaDevice {
@Override
public int getIcon() {
//TODO(b/121083246): This is not final icon for cast device, just for demo.
return R.drawable.ic_settings_print;
return com.android.internal.R.drawable.ic_settings_print;
}
@Override

View File

@@ -18,7 +18,6 @@ package com.android.settingslib.media;
import android.content.Context;
import android.util.Log;
import com.android.settingslib.R;
import com.android.settingslib.bluetooth.A2dpProfile;
import com.android.settingslib.bluetooth.HearingAidProfile;
import com.android.settingslib.bluetooth.LocalBluetoothManager;
@@ -53,7 +52,7 @@ public class PhoneMediaDevice extends MediaDevice {
@Override
public int getIcon() {
//TODO(b/117129183): This is not final icon for phone device, just for demo.
return R.drawable.ic_bt_cellphone;
return com.android.internal.R.drawable.ic_bt_cellphone;
}
@Override

View File

@@ -56,7 +56,7 @@ public class FooterPreference extends Preference {
}
private void init() {
setIcon(R.drawable.ic_info_outline_24dp);
setIcon(com.android.internal.R.drawable.ic_info_outline_24);
setKey(KEY_FOOTER);
setOrder(ORDER_FOOTER);
setSelectable(false);

View File

@@ -31,8 +31,6 @@ import android.graphics.PorterDuff.Mode;
import androidx.test.InstrumentationRegistry;
import androidx.test.runner.AndroidJUnit4;
import com.android.settingslib.R;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -45,7 +43,7 @@ public class UserIconDrawableTest {
public void getConstantState_shouldNotBeNull() {
final Bitmap b = BitmapFactory.decodeResource(
InstrumentationRegistry.getTargetContext().getResources(),
R.drawable.ic_mode_edit);
com.android.internal.R.drawable.ic_mode_edit);
mDrawable = new UserIconDrawable(100 /* size */).setIcon(b).bake();
assertThat(mDrawable.getConstantState()).isNotNull();
}

View File

@@ -1,26 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2016 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24.0"
android:viewportHeight="24.0"
android:tint="?android:attr/textColorSecondary">
<path
android:fillColor="#000000"
android:pathData="M11,17h2v-6h-2v6zM12,2C6.48,2 2,6.48 2,12s4.48,10 10,10 10,-4.48 10,-10S17.52,2 12,2zM12,20c-4.41,0 -8,-3.59 -8,-8s3.59,-8 8,-8 8,3.59 8,8 -3.59,8 -8,8zM11,9h2L13,7h-2v2z"/>
</vector>

View File

@@ -20,7 +20,6 @@ import static com.google.common.truth.Truth.assertThat;
import android.bluetooth.BluetoothDevice;
import android.graphics.drawable.Drawable;
import com.android.settingslib.R;
import com.android.settingslib.graph.BluetoothDeviceLayerDrawable;
import org.junit.Test;
@@ -34,7 +33,7 @@ public class BluetoothUtilsTest {
@Test
public void testGetBluetoothDrawable_noBatteryLevel_returnSimpleDrawable() {
final Drawable drawable = BluetoothUtils.getBluetoothDrawable(
RuntimeEnvironment.application, R.drawable.ic_bt_laptop,
RuntimeEnvironment.application, com.android.internal.R.drawable.ic_bt_laptop,
BluetoothDevice.BATTERY_LEVEL_UNKNOWN, 1 /* iconScale */);
assertThat(drawable).isNotInstanceOf(BluetoothDeviceLayerDrawable.class);
@@ -43,7 +42,7 @@ public class BluetoothUtilsTest {
@Test
public void testGetBluetoothDrawable_hasBatteryLevel_returnLayerDrawable() {
final Drawable drawable = BluetoothUtils.getBluetoothDrawable(
RuntimeEnvironment.application, R.drawable.ic_bt_laptop,
RuntimeEnvironment.application, com.android.internal.R.drawable.ic_bt_laptop,
10 /* batteryLevel */, 1 /* iconScale */);
assertThat(drawable).isInstanceOf(BluetoothDeviceLayerDrawable.class);

View File

@@ -12,8 +12,6 @@ import static com.google.common.truth.Truth.assertThat;
import android.content.pm.ActivityInfo;
import android.os.Bundle;
import com.android.settingslib.R;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -31,7 +29,7 @@ public class TileTest {
mActivityInfo = new ActivityInfo();
mActivityInfo.packageName = RuntimeEnvironment.application.getPackageName();
mActivityInfo.name = "abc";
mActivityInfo.icon = R.drawable.ic_plus;
mActivityInfo.icon = com.android.internal.R.drawable.ic_plus;
mActivityInfo.metaData = new Bundle();
mTile = new Tile(mActivityInfo, "category");
}

View File

@@ -53,8 +53,6 @@ import android.provider.Settings.Global;
import android.util.ArrayMap;
import android.util.Pair;
import com.android.settingslib.R;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -255,7 +253,7 @@ public class TileUtilsTest {
resolveInfo.activityInfo.metaData = new Bundle(oldMetadata);
resolveInfo.activityInfo.metaData.putInt(META_DATA_PREFERENCE_ICON,
R.drawable.ic_bt_cellphone);
com.android.internal.R.drawable.ic_bt_cellphone);
outTiles.clear();
TileUtils.getTilesForAction(mContext, UserHandle.CURRENT, IA_SETTINGS_ACTION, addedCache,
null /* defaultCategory */, outTiles, false /* usePriority */);

View File

@@ -31,7 +31,7 @@ import org.robolectric.RuntimeEnvironment;
@RunWith(RobolectricTestRunner.class)
public class BluetoothDeviceLayerDrawableTest {
private static final int RES_ID = R.drawable.ic_bt_cellphone;
private static final int RES_ID = com.android.internal.R.drawable.ic_bt_cellphone;
private static final int BATTERY_LEVEL = 15;
private static final float BATTERY_ICON_SCALE = 0.75f;
private static final int BATTERY_ICON_PADDING_TOP = 6;

View File

@@ -74,10 +74,10 @@ public class ActionButtonsPreferenceTest {
@Test
public void onBindViewHolder_setIcon_shouldShowButtonByDefault() {
mPref.setButton1Icon(R.drawable.ic_plus);
mPref.setButton2Icon(R.drawable.ic_plus);
mPref.setButton3Icon(R.drawable.ic_plus);
mPref.setButton4Icon(R.drawable.ic_plus);
mPref.setButton1Icon(com.android.internal.R.drawable.ic_plus);
mPref.setButton2Icon(com.android.internal.R.drawable.ic_plus);
mPref.setButton3Icon(com.android.internal.R.drawable.ic_plus);
mPref.setButton4Icon(com.android.internal.R.drawable.ic_plus);
mPref.onBindViewHolder(mHolder);
@@ -126,10 +126,10 @@ public class ActionButtonsPreferenceTest {
@Test
public void onBindViewHolder_setVisibleIsGoneAndSetIcon_shouldNotShowButton() {
mPref.setButton1Icon(R.drawable.ic_plus).setButton1Visible(false);
mPref.setButton2Icon(R.drawable.ic_plus).setButton2Visible(false);
mPref.setButton3Icon(R.drawable.ic_plus).setButton3Visible(false);
mPref.setButton4Icon(R.drawable.ic_plus).setButton4Visible(false);
mPref.setButton1Icon(com.android.internal.R.drawable.ic_plus).setButton1Visible(false);
mPref.setButton2Icon(com.android.internal.R.drawable.ic_plus).setButton2Visible(false);
mPref.setButton3Icon(com.android.internal.R.drawable.ic_plus).setButton3Visible(false);
mPref.setButton4Icon(com.android.internal.R.drawable.ic_plus).setButton4Visible(false);
mPref.onBindViewHolder(mHolder);
@@ -215,7 +215,7 @@ public class ActionButtonsPreferenceTest {
@Test
public void onBindViewHolder_setButtonIcon_iconMustDisplayAboveText() {
mPref.setButton1Text(R.string.install_other_apps);
mPref.setButton1Icon(R.drawable.ic_plus);
mPref.setButton1Icon(com.android.internal.R.drawable.ic_plus);
mPref.onBindViewHolder(mHolder);
final Drawable[] drawablesAroundText =

View File

@@ -54,7 +54,7 @@ public class AppEntitiesHeaderControllerTest {
mController = AppEntitiesHeaderController.newInstance(mContext,
mAppEntitiesHeaderView);
mAppEntityInfo = new AppEntityInfo.Builder()
.setIcon(mContext.getDrawable(R.drawable.ic_menu))
.setIcon(mContext.getDrawable(com.android.internal.R.drawable.ic_menu))
.setTitle(TITLE)
.setSummary(SUMMARY)
.setOnClickListener(v -> {

View File

@@ -58,7 +58,7 @@ public class BarChartPreferenceTest {
mHolder = PreferenceViewHolder.createInstanceForTests(mBarChartView);
mPreference = new BarChartPreference(mContext, null /* attrs */);
mIcon = mContext.getDrawable(R.drawable.ic_menu);
mIcon = mContext.getDrawable(com.android.internal.R.drawable.ic_menu);
mBarView1 = mBarChartView.findViewById(R.id.bar_view1);
mBarView2 = mBarChartView.findViewById(R.id.bar_view2);
mBarView3 = mBarChartView.findViewById(R.id.bar_view3);

View File

@@ -109,7 +109,7 @@
android:contentDescription="@string/accessibility_quick_settings_edit"
android:focusable="true"
android:padding="15dp"
android:src="@drawable/ic_mode_edit"
android:src="@*android:drawable/ic_mode_edit"
android:tint="?android:attr/colorForeground"/>
<com.android.systemui.statusbar.AlphaOptimizedFrameLayout

View File

@@ -24,7 +24,6 @@ import android.widget.Switch;
import com.android.internal.logging.nano.MetricsProto.MetricsEvent;
import com.android.systemui.R;
import com.android.systemui.R.drawable;
import com.android.systemui.plugins.ActivityStarter;
import com.android.systemui.plugins.qs.QSTile.BooleanState;
import com.android.systemui.qs.QSHost;
@@ -38,7 +37,7 @@ import javax.inject.Inject;
/** Quick settings tile: Location **/
public class LocationTile extends QSTileImpl<BooleanState> {
private final Icon mIcon = ResourceIcon.get(drawable.ic_signal_location);
private final Icon mIcon = ResourceIcon.get(com.android.internal.R.drawable.ic_signal_location);
private final LocationController mController;
private final KeyguardMonitor mKeyguard;

View File

@@ -111,7 +111,7 @@ public class NightDisplayTile extends QSTileImpl<BooleanState>
protected void handleUpdateState(BooleanState state, Object arg) {
state.value = mController.isActivated();
state.label = mContext.getString(R.string.quick_settings_night_display_label);
state.icon = ResourceIcon.get(R.drawable.ic_qs_night_display_on);
state.icon = ResourceIcon.get(com.android.internal.R.drawable.ic_qs_night_display_on);
state.expandedAccessibilityClassName = Switch.class.getName();
state.state = state.value ? Tile.STATE_ACTIVE : Tile.STATE_INACTIVE;
state.secondaryLabel = getSecondaryLabel(state.value);