diff options
author | John Spurlock <jspurlock@google.com> | 2015-05-11 17:46:28 -0400 |
---|---|---|
committer | John Spurlock <jspurlock@google.com> | 2015-05-11 17:49:36 -0400 |
commit | 4ec8b6029568021131b38d31df4c5be9ed7e20fa (patch) | |
tree | bd2a7840e0b4198c9b133d147c9ee6253552012a /packages/SystemUI/src | |
parent | e11ae116314a32ff1570f023b95e0ece3dbcc2e9 (diff) | |
download | frameworks_base-4ec8b6029568021131b38d31df4c5be9ed7e20fa.zip frameworks_base-4ec8b6029568021131b38d31df4c5be9ed7e20fa.tar.gz frameworks_base-4ec8b6029568021131b38d31df4c5be9ed7e20fa.tar.bz2 |
Zen: Distinct icon for DND = total silence.
Bug: 21032320
Change-Id: I0c7b8564c38b420081ee60ee244058b8039febf7
Diffstat (limited to 'packages/SystemUI/src')
3 files changed, 7 insertions, 2 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/DndTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/DndTile.java index 8205798..5f24619 100644 --- a/packages/SystemUI/src/com/android/systemui/qs/tiles/DndTile.java +++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/DndTile.java @@ -112,7 +112,7 @@ public class DndTile extends QSTile<QSTile.BooleanState> { R.string.accessibility_quick_settings_dnd_priority_on); break; case Global.ZEN_MODE_NO_INTERRUPTIONS: - state.icon = ResourceIcon.get(R.drawable.ic_qs_dnd_on); + state.icon = ResourceIcon.get(R.drawable.ic_qs_dnd_on_total_silence); state.label = mContext.getString(R.string.quick_settings_dnd_none_label); state.contentDescription = mContext.getString( R.string.accessibility_quick_settings_dnd_none_on); diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java index 0e8e844..5942b46 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java @@ -219,7 +219,8 @@ public class PhoneStatusBarPolicy { if (DndTile.isVisible(mContext) || DndTile.isCombinedIcon(mContext)) { zenVisible = mZen != Global.ZEN_MODE_OFF; - zenIconId = R.drawable.stat_sys_dnd; + zenIconId = mZen == Global.ZEN_MODE_NO_INTERRUPTIONS + ? R.drawable.stat_sys_dnd_total_silence : R.drawable.stat_sys_dnd; zenDescription = mContext.getString(R.string.quick_settings_dnd_label); } else if (mZen == Global.ZEN_MODE_NO_INTERRUPTIONS) { zenVisible = true; diff --git a/packages/SystemUI/src/com/android/systemui/volume/ZenFooter.java b/packages/SystemUI/src/com/android/systemui/volume/ZenFooter.java index ccb2b5a..66c4993 100644 --- a/packages/SystemUI/src/com/android/systemui/volume/ZenFooter.java +++ b/packages/SystemUI/src/com/android/systemui/volume/ZenFooter.java @@ -21,6 +21,7 @@ import android.provider.Settings.Global; import android.service.notification.ZenModeConfig; import android.util.AttributeSet; import android.view.View; +import android.widget.ImageView; import android.widget.LinearLayout; import android.widget.TextView; @@ -38,6 +39,7 @@ public class ZenFooter extends LinearLayout { private final Context mContext; private final SpTexts mSpTexts; + private ImageView mIcon; private TextView mSummaryLine1; private TextView mSummaryLine2; private TextView mEndNowButton; @@ -55,6 +57,7 @@ public class ZenFooter extends LinearLayout { @Override protected void onFinishInflate() { super.onFinishInflate(); + mIcon = (ImageView) findViewById(R.id.volume_zen_icon); mSummaryLine1 = (TextView) findViewById(R.id.volume_zen_summary_line_1); mSummaryLine2 = (TextView) findViewById(R.id.volume_zen_summary_line_2); mEndNowButton = (TextView) findViewById(R.id.volume_zen_end_now); @@ -115,6 +118,7 @@ public class ZenFooter extends LinearLayout { } public void update() { + mIcon.setImageResource(isZenNone() ? R.drawable.ic_dnd_total_silence : R.drawable.ic_dnd); final String line1 = isZenPriority() ? mContext.getString(R.string.interruption_level_priority) : isZenAlarms() ? mContext.getString(R.string.interruption_level_alarms) |