Merge "Add subtitle for Do not disturb" into qt-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
cf9b3d2e87
@@ -7432,6 +7432,9 @@
|
|||||||
<!-- Sound: Title for the Do not Disturb option and associated settings page. [CHAR LIMIT=50]-->
|
<!-- Sound: Title for the Do not Disturb option and associated settings page. [CHAR LIMIT=50]-->
|
||||||
<string name="zen_mode_settings_title">Do Not Disturb</string>
|
<string name="zen_mode_settings_title">Do Not Disturb</string>
|
||||||
|
|
||||||
|
<!-- Subtitle for the Do not Disturb slice. [CHAR LIMIT=50]-->
|
||||||
|
<string name="zen_mode_slice_subtitle">Limit interruptions</string>
|
||||||
|
|
||||||
<!-- Do not disturb: Title for the Do not Disturb dialog to turn on Do not disturb. [CHAR LIMIT=50]-->
|
<!-- Do not disturb: Title for the Do not Disturb dialog to turn on Do not disturb. [CHAR LIMIT=50]-->
|
||||||
<string name="zen_mode_settings_turn_on_dialog_title">Turn on Do Not Disturb</string>
|
<string name="zen_mode_settings_turn_on_dialog_title">Turn on Do Not Disturb</string>
|
||||||
|
|
||||||
|
@@ -73,6 +73,7 @@ public class ZenModeSliceBuilder {
|
|||||||
public static Slice getSlice(Context context) {
|
public static Slice getSlice(Context context) {
|
||||||
final boolean isZenModeEnabled = isZenModeEnabled(context);
|
final boolean isZenModeEnabled = isZenModeEnabled(context);
|
||||||
final CharSequence title = context.getText(R.string.zen_mode_settings_title);
|
final CharSequence title = context.getText(R.string.zen_mode_settings_title);
|
||||||
|
final CharSequence subtitle = context.getText(R.string.zen_mode_slice_subtitle);
|
||||||
@ColorInt final int color = Utils.getColorAccentDefaultColor(context);
|
@ColorInt final int color = Utils.getColorAccentDefaultColor(context);
|
||||||
final PendingIntent toggleAction = getBroadcastIntent(context);
|
final PendingIntent toggleAction = getBroadcastIntent(context);
|
||||||
final PendingIntent primaryAction = getPrimaryAction(context);
|
final PendingIntent primaryAction = getPrimaryAction(context);
|
||||||
@@ -87,6 +88,7 @@ public class ZenModeSliceBuilder {
|
|||||||
.setAccentColor(color)
|
.setAccentColor(color)
|
||||||
.addRow(new RowBuilder()
|
.addRow(new RowBuilder()
|
||||||
.setTitle(title)
|
.setTitle(title)
|
||||||
|
.setSubtitle(subtitle)
|
||||||
.addEndItem(toggleSliceAction)
|
.addEndItem(toggleSliceAction)
|
||||||
.setPrimaryAction(primarySliceAction))
|
.setPrimaryAction(primarySliceAction))
|
||||||
.build();
|
.build();
|
||||||
|
Reference in New Issue
Block a user