diff options
| author | 2022-08-08 15:27:50 +0000 | |
|---|---|---|
| committer | 2022-08-08 15:27:50 +0000 | |
| commit | 2b708c99c32333ee7de0f36b3b8cfd224b84ff23 (patch) | |
| tree | 788c620ca0462c5682c6f3b79115176f90376011 | |
| parent | 317201974a2cdd0f6d233a2c339acb07ec8116b2 (diff) | |
| parent | c9e9ec39b161b1607ad37fd55fa77f56557ee277 (diff) | |
Merge "Fix blocked sensor chip to hide if settings change." into tm-qpr-dev
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/dreams/DreamOverlayStatusBarViewController.java | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/dreams/DreamOverlayStatusBarViewController.java b/packages/SystemUI/src/com/android/systemui/dreams/DreamOverlayStatusBarViewController.java index de7bf28c01d6..55c1806e1899 100644 --- a/packages/SystemUI/src/com/android/systemui/dreams/DreamOverlayStatusBarViewController.java +++ b/packages/SystemUI/src/com/android/systemui/dreams/DreamOverlayStatusBarViewController.java @@ -215,16 +215,15 @@ public class DreamOverlayStatusBarViewController extends ViewController<DreamOve final boolean cameraBlocked = mSensorPrivacyController .isSensorBlocked(SensorPrivacyManager.Sensors.CAMERA); @DreamOverlayStatusBarView.StatusIconType int iconType = Resources.ID_NULL; - if (micBlocked && cameraBlocked) { - iconType = DreamOverlayStatusBarView.STATUS_ICON_MIC_CAMERA_DISABLED; - } else if (!micBlocked && cameraBlocked) { - iconType = DreamOverlayStatusBarView.STATUS_ICON_CAMERA_DISABLED; - } else if (micBlocked && !cameraBlocked) { - iconType = DreamOverlayStatusBarView.STATUS_ICON_MIC_DISABLED; - } - if (iconType != Resources.ID_NULL) { - showIcon(iconType, true); - } + showIcon( + DreamOverlayStatusBarView.STATUS_ICON_CAMERA_DISABLED, + !micBlocked && cameraBlocked); + showIcon( + DreamOverlayStatusBarView.STATUS_ICON_MIC_DISABLED, + micBlocked && !cameraBlocked); + showIcon( + DreamOverlayStatusBarView.STATUS_ICON_MIC_CAMERA_DISABLED, + micBlocked && cameraBlocked); } private String buildNotificationsContentDescription(int notificationCount) { |