Files
frameworks_base/packages/SystemUI/res/values/drawables.xml
Robert Horvath db0a9431dc Add support for HW privacy toggles in sensor unblock dialog
- Adapt strings for when HW toggle is blocking sensor access
- Use hw-toggle specific resource names that can be overlayed by OEMs
  to provide device-specific guidance (strings, icons)
- Call #onSensorBlockedChanged when going from blocked by SW toggle to
  blocked by HW toggle (still blocked, but for a different reason) to
  update UI
- Change action button to open corresponding sensor privacy Settings
  page if blocked by HW toggle. Open mic settings if both mic & camera
  are blocked, since assuming a 3-way-switch (unblocked -> mic blocked
  -> mic & camera blocked) unblocking mic will also unblock the camera.

Bug: 220717475
Test: manually, on device with physical mic toggle
Change-Id: I64e37f29e73fb48d1d53a35a4ff72d5a77c6a6bc
2022-03-28 18:53:52 +00:00

27 lines
1.4 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!--
~ Copyright (C) 2022 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.
-->
<resources>
<!-- Drawable shown for the sensor unblock dialog when blocked by the hardware camera toggle -->
<drawable name="unblock_hw_sensor_camera">@drawable/ic_videocam_off</drawable>
<!-- Drawable shown for the sensor unblock dialog when blocked by the hardware microphone toggle -->
<drawable name="unblock_hw_sensor_microphone">@drawable/ic_mic_off</drawable>
<!-- Drawable shown for the sensor unblock dialog when blocked by the hardware privacy toggle -->
<drawable name="unblock_hw_sensor_all">@drawable/ic_videocam_off</drawable>
<!-- Second drawable shown for the sensor unblock dialog when blocked by the hardware privacy toggle -->
<drawable name="unblock_hw_sensor_all_second">@drawable/ic_mic_off</drawable>
</resources>