Fix some lint for Settings

Bug: 234570979
Test: Manually with Settings App
Change-Id: I4cd66be1df5499c070fd7f80caf9a5ab2873b93d
This commit is contained in:
Chaohui Wang
2022-11-04 11:01:41 +08:00
parent eeb92a8cab
commit dbe73f6603
16 changed files with 10 additions and 32 deletions

View File

@@ -19,7 +19,7 @@
android:height="24dp" android:height="24dp"
android:viewportWidth="24.0" android:viewportWidth="24.0"
android:viewportHeight="24.0" android:viewportHeight="24.0"
android:tint="?android:attr/textColorSecondary">> android:tint="?android:attr/textColorSecondary">
<path <path
android:fillColor="#FF000000" android:fillColor="#FF000000"
android:pathData="M12,2L3.82,5.64v5.45c0,5.05 3.49,9.76 8.18,10.91c4.69,-1.15 8.18,-5.86 8.18,-10.91V5.64L12,2zM18.18,11.09c0,1.55 -0.41,3.05 -1.1,4.38C15.77,14.5 13.4,14 12,14s-3.77,0.5 -5.08,1.47c-0.69,-1.33 -1.1,-2.83 -1.1,-4.38V6.94L12,4.19l6.18,2.75V11.09z"/> android:pathData="M12,2L3.82,5.64v5.45c0,5.05 3.49,9.76 8.18,10.91c4.69,-1.15 8.18,-5.86 8.18,-10.91V5.64L12,2zM18.18,11.09c0,1.55 -0.41,3.05 -1.1,4.38C15.77,14.5 13.4,14 12,14s-3.77,0.5 -5.08,1.47c-0.69,-1.33 -1.1,-2.83 -1.1,-4.38V6.94L12,4.19l6.18,2.75V11.09z"/>

View File

@@ -29,7 +29,6 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:singleLine="false"
android:ellipsize="marquee" android:ellipsize="marquee"
android:textDirection="locale"/> android:textDirection="locale"/>
@@ -40,7 +39,6 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:layout_marginTop="2dp" android:layout_marginTop="2dp"
android:singleLine="false"
android:ellipsize="marquee" android:ellipsize="marquee"
android:textDirection="locale"/> android:textDirection="locale"/>

View File

@@ -39,7 +39,6 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:gravity="center" android:gravity="center"
android:singleLine="false"
android:ellipsize="marquee" android:ellipsize="marquee"
android:textDirection="locale" android:textDirection="locale"
android:layout_marginTop="24dp" android:layout_marginTop="24dp"

View File

@@ -31,7 +31,6 @@
style="@style/TextAppearance.EntityHeaderTitle" style="@style/TextAppearance.EntityHeaderTitle"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:singleLine="false"
android:ellipsize="marquee" android:ellipsize="marquee"
android:textDirection="locale"/> android:textDirection="locale"/>
@@ -41,7 +40,6 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="@dimen/bluetooth_find_broadcast_header_top_margin" android:layout_marginTop="@dimen/bluetooth_find_broadcast_header_top_margin"
android:singleLine="false"
android:ellipsize="marquee" android:ellipsize="marquee"
android:textDirection="locale"/> android:textDirection="locale"/>

View File

@@ -23,7 +23,6 @@
android:layout_width="match_parent"> android:layout_width="match_parent">
<LinearLayout <LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:paddingStart="16dip" android:paddingStart="16dip"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_width="match_parent" android:layout_width="match_parent"

View File

@@ -23,7 +23,6 @@
android:layout_width="match_parent"> android:layout_width="match_parent">
<LinearLayout <LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_width="match_parent" android:layout_width="match_parent"
android:orientation="vertical"> android:orientation="vertical">

View File

@@ -25,7 +25,7 @@
android:layout_height="match_parent" android:layout_height="match_parent"
android:orientation="vertical"> android:orientation="vertical">
<HorizontalScrollView xmlns:android="http://schemas.android.com/apk/res/android" <HorizontalScrollView
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:scrollbars="none" android:scrollbars="none"

View File

@@ -33,7 +33,6 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:singleLine="false"
android:ellipsize="marquee" android:ellipsize="marquee"
android:textDirection="locale"/> android:textDirection="locale"/>
@@ -44,7 +43,6 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:layout_marginTop="4dp" android:layout_marginTop="4dp"
android:singleLine="false"
android:ellipsize="marquee" android:ellipsize="marquee"
android:textDirection="locale"/> android:textDirection="locale"/>

View File

@@ -16,7 +16,6 @@
--> -->
<FrameLayout <FrameLayout
xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:settings="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content"> android:layout_height="wrap_content">
@@ -29,7 +28,6 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginVertical="8dp" android:layout_marginVertical="8dp"
android:layout_marginHorizontal="16dp" android:layout_marginHorizontal="16dp"/>
settings:allowDividerBelow="true"/>
</FrameLayout> </FrameLayout>

View File

@@ -24,7 +24,7 @@
android:paddingStart="24dip" android:paddingStart="24dip"
android:minHeight="?android:attr/listPreferredItemHeight" android:minHeight="?android:attr/listPreferredItemHeight"
android:background="?android:attr/selectableItemBackground"> android:background="?android:attr/selectableItemBackground">
<RadioButton xmlns:android="http://schemas.android.com/apk/res/android" <RadioButton
android:id="@+id/button" android:id="@+id/button"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="fill_parent" android:layout_height="fill_parent"

View File

@@ -28,7 +28,6 @@
android:layout_width="match_parent"/> android:layout_width="match_parent"/>
<View <View
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/footer_divider" android:id="@+id/footer_divider"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="@dimen/horizontal_divider_height" android:layout_height="@dimen/horizontal_divider_height"

View File

@@ -136,7 +136,6 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:orientation="horizontal" android:orientation="horizontal"
android:layout_marginStart="30dp" android:layout_marginStart="30dp"
android:singleLine="false"
android:textColor="?android:attr/textColorPrimary" android:textColor="?android:attr/textColorPrimary"
android:textSize="10sp" android:textSize="10sp"
android:fontFamily="monospace" android:fontFamily="monospace"
@@ -149,7 +148,6 @@
android:orientation="horizontal" android:orientation="horizontal"
android:layout_marginStart="30dp" android:layout_marginStart="30dp"
android:layout_marginBottom="6dp" android:layout_marginBottom="6dp"
android:singleLine="false"
android:textColor="?android:attr/textColorPrimary" android:textColor="?android:attr/textColorPrimary"
android:textSize="10sp" android:textSize="10sp"
android:fontFamily="monospace" android:fontFamily="monospace"

View File

@@ -38,7 +38,7 @@
android:layout_marginEnd="8dip" android:layout_marginEnd="8dip"
android:contentDescription="@string/sync_active" /> android:contentDescription="@string/sync_active" />
<Switch xmlns:android="http://schemas.android.com/apk/res/android" <Switch
android:id="@android:id/switch_widget" android:id="@android:id/switch_widget"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"

View File

@@ -69,7 +69,6 @@
<CheckBox style="@style/vpn_value" <CheckBox style="@style/vpn_value"
android:id="@+id/mppe" android:id="@+id/mppe"
android:text="@string/vpn_mppe" android:text="@string/vpn_mppe"
android:singleLine="false"
android:visibility="gone"/> android:visibility="gone"/>
<LinearLayout android:id="@+id/l2tp" <LinearLayout android:id="@+id/l2tp"
@@ -147,7 +146,6 @@
<CheckBox style="@style/vpn_value" <CheckBox style="@style/vpn_value"
android:id="@+id/show_options" android:id="@+id/show_options"
android:singleLine="false"
android:text="@string/vpn_show_options"/> android:text="@string/vpn_show_options"/>
</LinearLayout> </LinearLayout>
@@ -243,7 +241,6 @@
<CheckBox style="@style/vpn_value" <CheckBox style="@style/vpn_value"
android:id="@+id/save_login" android:id="@+id/save_login"
android:singleLine="false"
android:text="@string/vpn_save_login"/> android:text="@string/vpn_save_login"/>
</LinearLayout> </LinearLayout>
@@ -254,11 +251,9 @@
android:animateLayoutChanges="true"> android:animateLayoutChanges="true">
<CheckBox style="@style/vpn_value" <CheckBox style="@style/vpn_value"
android:id="@+id/always_on_vpn" android:id="@+id/always_on_vpn"
android:singleLine="false"
android:text="@string/vpn_menu_lockdown"/> android:text="@string/vpn_menu_lockdown"/>
<TextView style="@style/vpn_warning" <TextView style="@style/vpn_warning"
android:id="@+id/always_on_invalid_reason" android:id="@+id/always_on_invalid_reason"
android:singleLine="false"
android:visibility="gone"/> android:visibility="gone"/>
</LinearLayout> </LinearLayout>
</LinearLayout> </LinearLayout>

View File

@@ -16,8 +16,7 @@
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content"> android:layout_height="wrap_content">
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" <RelativeLayout android:id="@+id/zen_mode_settings_senders_overlay_view"
android:id="@+id/zen_mode_settings_senders_overlay_view"
android:layout_centerInParent="true" android:layout_centerInParent="true"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"

View File

@@ -250,8 +250,7 @@ public class BluetoothPairingDialogFragment extends InstrumentedDialogFragment i
CheckBox alphanumericPin = (CheckBox) view.findViewById(R.id.alphanumeric_pin); CheckBox alphanumericPin = (CheckBox) view.findViewById(R.id.alphanumeric_pin);
CheckBox contactSharing = (CheckBox) view.findViewById( CheckBox contactSharing = (CheckBox) view.findViewById(
R.id.phonebook_sharing_message_entry_pin); R.id.phonebook_sharing_message_entry_pin);
contactSharing.setText(getString(R.string.bluetooth_pairing_shares_phonebook, contactSharing.setText(getString(R.string.bluetooth_pairing_shares_phonebook));
mPairingController.getDeviceName()));
EditText pairingView = (EditText) view.findViewById(R.id.text); EditText pairingView = (EditText) view.findViewById(R.id.text);
contactSharing.setVisibility( contactSharing.setVisibility(
@@ -342,8 +341,7 @@ public class BluetoothPairingDialogFragment extends InstrumentedDialogFragment i
TextView messagePairing = (TextView) view.findViewById(R.id.pairing_code_message); TextView messagePairing = (TextView) view.findViewById(R.id.pairing_code_message);
CheckBox contactSharing = (CheckBox) view.findViewById( CheckBox contactSharing = (CheckBox) view.findViewById(
R.id.phonebook_sharing_message_confirm_pin); R.id.phonebook_sharing_message_confirm_pin);
contactSharing.setText(getString(R.string.bluetooth_pairing_shares_phonebook, contactSharing.setText(getString(R.string.bluetooth_pairing_shares_phonebook));
mPairingController.getDeviceName()));
contactSharing.setVisibility( contactSharing.setVisibility(
mPairingController.isContactSharingVisible() ? View.VISIBLE : View.GONE); mPairingController.isContactSharingVisible() ? View.VISIBLE : View.GONE);