Changes for upcoming theming changes in Settings: - replacing some margins with padding - merging some (switch pref + info pref) combos into a single preference. I flagged the one that was already launched, but changed the other directly - added some section headers (unflagged) - moved all app wide notification settings to a single section (unflagged) - changed two plain text prefs into TopIntroPreference, the dedicated pref type for that sort of UI - fixed some UI issues with 'Show more categories' appearing too often - removed a duplicate notifcation channel label (unflagged) - replaced a button layout preference with ButtonPreference (unflagged) Test: manual review with is_expressive_design_enabled on and off Test: atest com.android.settings.notification.app Flag: EXEMPT this feature is not using aconfig for flagging Bug: 349652992 Change-Id: I2acd7b2eb9dbcf6929143bfde99cd67163f1f95d
176 lines
8.1 KiB
XML
176 lines
8.1 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
Copyright (C) 2020 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.
|
|
-->
|
|
|
|
<LinearLayout
|
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
android:id="@+id/app_entities_header"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:gravity="center"
|
|
android:paddingStart="?android:attr/listPreferredItemPaddingStart"
|
|
android:paddingEnd="?android:attr/listPreferredItemPaddingEnd"
|
|
android:paddingTop="@dimen/notification_importance_toggle_marginTop"
|
|
android:paddingBottom="@dimen/notification_importance_toggle_marginTop"
|
|
android:orientation="vertical">
|
|
|
|
<com.android.settings.notification.NotificationButtonRelativeLayout
|
|
android:id="@+id/priority_group"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:padding="@dimen/notification_importance_button_padding"
|
|
android:clickable="true"
|
|
android:focusable="true">
|
|
<LinearLayout
|
|
android:id="@+id/icon_label_container"
|
|
android:gravity="center_vertical"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="horizontal">
|
|
<ImageView
|
|
android:id="@+id/icon"
|
|
android:src="@drawable/ic_important_outline"
|
|
android:background="@android:color/transparent"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:clickable="false"
|
|
android:focusable="false"/>
|
|
<TextView
|
|
android:id="@+id/label"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:ellipsize="end"
|
|
android:maxLines="1"
|
|
android:clickable="false"
|
|
android:focusable="false"
|
|
android:layout_marginStart="@dimen/notification_importance_drawable_padding"
|
|
android:textAppearance="@style/TextAppearance.NotificationImportanceButton.Unselected"
|
|
android:text="@string/notification_priority_title"/>
|
|
</LinearLayout>
|
|
<TextView
|
|
android:id="@+id/summary"
|
|
android:paddingTop="@dimen/notification_importance_button_padding"
|
|
android:text="@string/notification_channel_summary_priority"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:clickable="false"
|
|
android:focusable="false"
|
|
android:ellipsize="end"
|
|
android:maxLines="4"
|
|
android:layout_below="@id/icon_label_container"
|
|
android:textAppearance="@style/TextAppearance.NotificationImportanceDetail"
|
|
android:visibility="gone" />
|
|
</com.android.settings.notification.NotificationButtonRelativeLayout>
|
|
|
|
<com.android.settings.notification.NotificationButtonRelativeLayout
|
|
android:id="@+id/alert"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:padding="@dimen/notification_importance_button_padding"
|
|
android:layout_marginTop="@dimen/notification_importance_button_separation"
|
|
android:clickable="true"
|
|
android:focusable="true">
|
|
<LinearLayout
|
|
android:id="@+id/icon_label_container"
|
|
android:gravity="center_vertical"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="horizontal">
|
|
<ImageView
|
|
android:id="@+id/icon"
|
|
android:src="@drawable/ic_notifications_alert"
|
|
android:background="@android:color/transparent"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:clickable="false"
|
|
android:focusable="false"/>
|
|
<TextView
|
|
android:id="@+id/label"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:ellipsize="end"
|
|
android:maxLines="1"
|
|
android:clickable="false"
|
|
android:focusable="false"
|
|
android:layout_marginStart="@dimen/notification_importance_drawable_padding"
|
|
android:textAppearance="@style/TextAppearance.NotificationImportanceButton.Unselected"
|
|
android:text="@string/notification_alert_title"/>
|
|
</LinearLayout>
|
|
<TextView
|
|
android:id="@+id/summary"
|
|
android:paddingTop="@dimen/notification_importance_button_padding"
|
|
android:text="@string/notification_channel_summary_default"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:clickable="false"
|
|
android:focusable="false"
|
|
android:ellipsize="end"
|
|
android:maxLines="2"
|
|
android:layout_below="@id/icon_label_container"
|
|
android:textAppearance="@style/TextAppearance.NotificationImportanceDetail"
|
|
android:visibility="gone" />
|
|
</com.android.settings.notification.NotificationButtonRelativeLayout>
|
|
|
|
<com.android.settings.notification.NotificationButtonRelativeLayout
|
|
android:id="@+id/silence"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:padding="@dimen/notification_importance_button_padding"
|
|
android:layout_marginTop="@dimen/notification_importance_button_separation"
|
|
android:clickable="true"
|
|
android:focusable="true">
|
|
<LinearLayout
|
|
android:id="@+id/icon_label_container"
|
|
android:gravity="center_vertical"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="horizontal">
|
|
<ImageView
|
|
android:id="@+id/icon"
|
|
android:src="@drawable/ic_notifications_off_24dp"
|
|
android:background="@android:color/transparent"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:clickable="false"
|
|
android:focusable="false"/>
|
|
<TextView
|
|
android:id="@+id/label"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:ellipsize="end"
|
|
android:maxLines="1"
|
|
android:clickable="false"
|
|
android:focusable="false"
|
|
android:layout_marginStart="@dimen/notification_importance_drawable_padding"
|
|
android:textAppearance="@style/TextAppearance.NotificationImportanceButton.Unselected"
|
|
android:text="@string/notification_silence_title"/>
|
|
</LinearLayout>
|
|
<TextView
|
|
android:id="@+id/summary"
|
|
android:paddingTop="@dimen/notification_importance_button_padding"
|
|
android:text="@string/notification_conversation_summary_low"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:clickable="false"
|
|
android:focusable="false"
|
|
android:ellipsize="end"
|
|
android:maxLines="2"
|
|
android:layout_below="@id/icon_label_container"
|
|
android:textAppearance="@style/TextAppearance.NotificationImportanceDetail"
|
|
android:visibility="gone" />
|
|
</com.android.settings.notification.NotificationButtonRelativeLayout>
|
|
|
|
</LinearLayout> |