Commit Graph

295 Commits

Author SHA1 Message Date
changbetty
c706aa6108 Make bluetooth switch not discoverable via SliceDeepLinkTrampoline
Bug: 244423101
Test: make RunSettingsRoboTests ROBOTEST_FILTER=BluetoothSwitchPreferenceControllerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=BluetoothDashboardFragmentTest
Test: manual test by test apk

Change-Id: I13562d227e06627fac33239a9d21fd405a18d012
2022-11-08 08:50:29 +00:00
SongFerngWang
76870250e8 Add owner for job handover
CP from the AOSP aosp/2200280.

Bug: 244524317
Test: NA
Change-Id: I9259596811cba08a21b78eebbe2f847e1aa6818c
Merged-In: I9259596811cba08a21b78eebbe2f847e1aa6818c
2022-09-02 07:01:25 +00:00
Jason Chiu
5df14831b8 Make bluetooth not discoverable via large screen deep link flow
Deep links on large screen devices starts a homepage activity on the
left pane, and then starts the target activity on the right pane. This
flow overrides the calling package, and the target activity can't know
who initially calls it.

Thus, we store the initial calling package in the intent, so the
Connected devices page is able to make bluetooth not discoverable when
it's called from unintended apps on large screen devices.

Bug: 234440688
Test: robotest, manual
Change-Id: I4ddcd4e083c002ece9d10aabdb4af4a41de55ce7
Merged-In: I4ddcd4e083c002ece9d10aabdb4af4a41de55ce7
2022-06-24 08:16:41 +00:00
jasonwshsu
acd3f94fde Pop up pairing another ear dialog when detecting hearing aid is a set
* Pop up dialog in 'Connected deivce' page and 'Accessibility -> Hearing
  aids' page

Bug: 225117454
Bug: 226511985
Test: make RunSettingsRoboTests ROBOTEST_FILTER=HearingAidPairingDialogFragmentTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=AvailableMediaDeviceGroupControllerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=AccessibilityHearingAidPreferenceControllerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=HearingAidUtils

Change-Id: I34a1e3ac680a7efe97dc501bfbe93f840ad16364
2022-05-14 22:16:22 +00:00
Hugh Chen
205752dcf2 Make bluetooth not discoverable via SliceDeepLinkTrampoline
- Don't let device be discovered when the user launch "Connected Devices
  settings" through SliceDeepLinkTrampoline.

Bug: 228450811
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: I5490b58675b1fd9fc36305766867f65caa6ccb6c
2022-05-10 09:47:19 +00:00
Hugh Chen
ec0c171735 Fix can't select the [USB Tethering] item in [Developer Options]
- This CL is using 'USB_CONFIGURED' to check whether the USB enumeration
  is completed from the intent. If 'USB_CONFIGURED' is true then update
  the UI.

Bug: 229200265
Test: make -j65 RunSettingsRoboTests
Change-Id: Icab05e37ae3fcc9f1bf404a610fc97c368c453f5
2022-05-03 08:00:58 +00:00
Hugh Chen
aadc44ae26 Fix default usb settings will set wrong function when onPause()
Bug: 229200265
Test: make -j64 RunSettingsRoboTests
Change-Id: Ibee2d39af8b341d03117d96029446ddcd45921fe
2022-04-18 12:16:57 +00:00
Treehugger Robot
c78c5e1129 Merge "Restart the MTP connection when changing transcode enabled" am: 8109ad8033 am: df16e4b74c am: f5246d8a8c
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1882150

Change-Id: I4d0f5d3bb5d11b1217de60f6b22e5544c8d00bfa
2022-02-16 13:52:02 +00:00
Treehugger Robot
f5246d8a8c Merge "Restart the MTP connection when changing transcode enabled" am: 8109ad8033 am: df16e4b74c
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1882150

Change-Id: Ib92a9c70e554ff53f452cae5cf45d6be511da39b
2022-02-16 13:33:21 +00:00
Treehugger Robot
df16e4b74c Merge "Restart the MTP connection when changing transcode enabled" am: 8109ad8033
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1882150

Change-Id: I180666f8edc9fdb69fcdec20b9ae2730240ff923
2022-02-16 13:08:35 +00:00
Treehugger Robot
8109ad8033 Merge "Restart the MTP connection when changing transcode enabled" 2022-02-16 09:58:58 +00:00
Jack Yu
29e46bd01e Do not let guest user disable secure nfc am: a579ca7554 am: 1009054124 am: b85416796d am: 05dfb08c80 am: 147f4bc01d
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16691815

Change-Id: Ibb578e5efdfffa772c785cb482de853a19faf0b7
2022-01-28 23:29:42 +00:00
Jack Yu
147f4bc01d Do not let guest user disable secure nfc am: a579ca7554 am: 1009054124 am: b85416796d am: 05dfb08c80
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16691815

Change-Id: Ib69851dd1d88fcba84af0cf940b6f949aab15355
2022-01-28 23:14:00 +00:00
Jack Yu
05dfb08c80 Do not let guest user disable secure nfc am: a579ca7554 am: 1009054124 am: b85416796d
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16691815

Change-Id: I72ccad504b36bd1112660cc180be93c210ae66c4
2022-01-28 22:53:00 +00:00
Jack Yu
b85416796d Do not let guest user disable secure nfc am: a579ca7554 am: 1009054124
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16691815

Change-Id: I9879ba034ae2b8d7a964a4d6c9d700bad55b636e
2022-01-28 22:31:38 +00:00
Jack Yu
1009054124 Do not let guest user disable secure nfc am: a579ca7554
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16691815

Change-Id: Ic68c6849bb65875aea6286d415c66ae8a9f57dfa
2022-01-28 22:19:10 +00:00
Jack Yu
a579ca7554 Do not let guest user disable secure nfc
Bug: 209446496
Test: manual
Merged-In: I7253f7f08fde04e30400a30d9a0d24f1ceff04b0
Change-Id: I7253f7f08fde04e30400a30d9a0d24f1ceff04b0
(cherry picked from commit d9e3e6e4b1)
2022-01-22 07:56:25 +00:00
Jack Yu
d9e3e6e4b1 Do not let guest user disable secure nfc
Bug: 209446496
Test: manual
Change-Id: I7253f7f08fde04e30400a30d9a0d24f1ceff04b0
2022-01-19 10:43:10 +00:00
Bill Yi
39df254c94 Merge sc-qpr1 to aosp-master - DO NOT MERGE
Merged-In: Id5612dfa82e11037cd95b0ef0f5a507d9c86dd48
Merged-In: I4f51c80cf4e32c384afad849c04c7c6afa065767
Change-Id: Ie466180309fcfe540492967e8bf3587b34928ded
2022-01-06 18:39:02 -08:00
Michael Groover
d1f76eea72 Merge "Add unaudited exported flag to exposed runtime receivers" 2022-01-03 17:35:02 +00:00
Treehugger Robot
a86e838b02 Merge "Settings: Extend the data role swap timeout value" am: bb994f627f am: df2a22f104 am: 26bf610fd9 am: 16a3f98b71
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1912875

Change-Id: Icb00bc53ba6d7fb2e3fbf85a4c7a42b1dec99880
2021-12-15 07:47:41 +00:00
Treehugger Robot
16a3f98b71 Merge "Settings: Extend the data role swap timeout value" am: bb994f627f am: df2a22f104 am: 26bf610fd9
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1912875

Change-Id: I86be84ebc20266fb0b6af1b2faa196def582da55
2021-12-15 07:35:30 +00:00
Treehugger Robot
26bf610fd9 Merge "Settings: Extend the data role swap timeout value" am: bb994f627f am: df2a22f104
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1912875

Change-Id: I0d456509b02715b141a6110ef89a476995ce5d67
2021-12-15 07:23:26 +00:00
Treehugger Robot
bb994f627f Merge "Settings: Extend the data role swap timeout value" 2021-12-15 06:49:44 +00:00
Michael Groover
911f7e7aa9 Add unaudited exported flag to exposed runtime receivers
Android T allows apps to declare a runtime receiver as not exported
by invoking registerReceiver with a new RECEIVER_NOT_EXPORTED flag;
receivers registered with this flag will only receive broadcasts from
the platform and the app itself. However to ensure developers can
properly protect their receivers, all apps targeting T or later
registering a receiver for non-system broadcasts must specify either
the exported or not exported flag when invoking #registerReceiver;
if one of these flags is not provided, the platform will throw a
SecurityException. This commit updates all the exposed receivers
with a new RECEIVER_EXPORTED_UNAUDITED flag to maintain the existing
behavior of exporting the receiver while also flagging the receiver
for audit before the T release.

Bug: 161145287
Test: Build
Change-Id: Ie97372efebd8258d9a4c503771d55109a85e6ae9
2021-12-09 20:34:02 -08:00
hoffc
d4f420350d Settings: Extend the data role swap timeout value
Switching USB data role from device to host, it takes more than 3s in some devices, so 3s timeout is not enough.

Extend 3s timeout to 4s to be compatible with some devices with slow swap.

Bug: 209541948

Change-Id: I172498d66c5b12166162f2c55d94f0d441c7459c
2021-12-07 17:23:41 +08:00
Zim
b735393c9e Restart the MTP connection when changing transcode enabled
To workaround some issues with transcoded file sizes transferred
via MTP on Windows machines, we restart the MTP connection after
changing the transcode flag.

Test: Manual
Bug: 184117074
Bug: 190422448
Change-Id: I8d151117e1f5d23c3ec20e8c7a4b4546c96f2c84
2021-11-26 14:36:59 +00:00
Hugh Chen
3f280c15b1 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission
- Only enable device can be discoverable when the user launch
  "Connected Devices settings" through settings and systemui

Bug: 194695497
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: Ia04ab759b737acf30b782f5c5831dd59f25fb257
(cherry picked from commit d3abbb9821)
(cherry picked from commit b1adf980a5)
Merged-In:Ia04ab759b737acf30b782f5c5831dd59f25fb257
2021-11-24 23:23:54 +00:00
Hugh Chen
f5a236e0e8 Fix NPE on UsbManager in w/o usb devices
Bug: 206987614
Test: make -j64 RunSettingsRoboTests
Change-Id: I9ed4c2e803f3e7018518380667658ca0015f31a7
2021-11-23 09:11:22 +00:00
Hugh Chen
4640a2a077 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission am: b1adf980a5
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16144999

Change-Id: Ieb2beb22a55230c7e7f283f6886b340b7821d67f
2021-11-09 07:27:19 +00:00
Hugh Chen
be094163b8 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission am: 58d81fbbb4
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16130956

Change-Id: I6572efe48fb0ad0159e0177459d1929aaa4f86ce
2021-11-09 07:24:27 +00:00
Hugh Chen
528d40e4d1 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission
- Only enable device can be discoverable when the user launch
  "Connected Devices settings" through settings and systemui

Bug: 194695497
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: Ia04ab759b737acf30b782f5c5831dd59f25fb257
(cherry picked from commit d3abbb9821)
2021-11-01 07:01:34 +00:00
Hugh Chen
249f9e2696 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission
- Only enable device can be discoverable when the user launch
  "Connected Devices settings" through settings and systemui

Bug: 194695497
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: Ia04ab759b737acf30b782f5c5831dd59f25fb257
(cherry picked from commit d3abbb9821)
2021-11-01 07:00:33 +00:00
Hugh Chen
d7c50f7952 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission
- Only enable device can be discoverable when the user launch
  "Connected Devices settings" through settings and systemui

Bug: 194695497
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: Ia04ab759b737acf30b782f5c5831dd59f25fb257
(cherry picked from commit d3abbb9821)
2021-11-01 06:58:55 +00:00
Hugh Chen
b1adf980a5 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission
- Only enable device can be discoverable when the user launch
  "Connected Devices settings" through settings and systemui

Bug: 194695497
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: Ia04ab759b737acf30b782f5c5831dd59f25fb257
(cherry picked from commit d3abbb9821)
2021-11-01 06:57:09 +00:00
Hugh Chen
58d81fbbb4 RESTRICT AUTOMERGE Fix make Bluetooth discoverable without additional permission
- Only enable device can be discoverable when the user launch
  "Connected Devices settings" through settings and systemui

Bug: 194695497
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: Ia04ab759b737acf30b782f5c5831dd59f25fb257
2021-11-01 06:56:12 +00:00
Hugh Chen
d3abbb9821 Fix make Bluetooth discoverable without additional permission
- Only enable device can be discoverable when the user launch
  "Connected Devices settings" through settings and systemui

Bug: 194695497
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.

Change-Id: Ia04ab759b737acf30b782f5c5831dd59f25fb257
2021-10-28 09:14:46 +00:00
Chienyuan
f06def46f7 RESTRICT AUTOMERGE Remove connection preferences "Files received via Bluetooth" am: 1b9a21ffb5
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16048451

Change-Id: I7a693b6644e200a7aa66f09704e39c178aa2baa7
2021-10-21 15:18:13 +00:00
TreeHugger Robot
c1770fe4cf Merge "RESTRICT AUTOMERGE Remove connection preferences "Files received via Bluetooth"" into sc-v2-dev 2021-10-21 15:04:46 +00:00
TreeHugger Robot
5c93284201 Merge "Update UWB toggle display after lifecycle events." into sc-qpr1-dev am: faf452bf94 am: b097e09dd7 am: cc6de81b52
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16047401

Change-Id: I7b10e68e133c04feff0fc1729cccc921ddfc1b50
2021-10-20 05:22:09 +00:00
TreeHugger Robot
b097e09dd7 Merge "Update UWB toggle display after lifecycle events." into sc-qpr1-dev am: faf452bf94
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/16047401

Change-Id: I34e321f6a32401f5b0adcaacf90a63d32e7bccef
2021-10-20 04:53:31 +00:00
Joy Babafemi
06a39e9e34 Update UWB toggle display after lifecycle events.
Bug: 201790864
Test: Manual
Change-Id: I05cb52331fe106017b2cb6718a897690720725db
2021-10-15 23:48:41 +00:00
Chienyuan
1b9a21ffb5 RESTRICT AUTOMERGE Remove connection preferences "Files received via Bluetooth"
Bug: 197609370
Bug: 201630499
Test: manual
Change-Id: I597a2105ca851dd41d92109f7b1a5d0137942601
(cherry picked from commit 5be9255ddf)
2021-10-14 08:47:16 +00:00
Chienyuan
5be9255ddf Remove connection preferences "Files received via Bluetooth"
Bug: 197609370
Bug: 201630499
Test: manual
Change-Id: I597a2105ca851dd41d92109f7b1a5d0137942601
2021-10-09 01:19:00 +08:00
TreeHugger Robot
a5cc9839c2 Merge "Fix USB tethering is not turned on with a single tap" into sc-qpr1-dev am: b370bfe77d
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/15724814

Change-Id: Ibb65b7999bdc331c4b15363bce71ece51a448c0e
2021-09-08 08:09:04 +00:00
Hugh Chen
ffeefd4d11 Fix USB tethering is not turned on with a single tap
Before this CL, the USB default settings will set default usb functions
to RNDIS when tethering is started. Because in some devices, the NCM
is used instead of RNDIS to start tethering. If RNDIS is set in the
device that uses NCM to start tethering, it will cause start
tethering failed.

This CL will use the current functions to set default usb functions
to fix this issue.

Bug: 195068679
Bug: 197026638
Test: make -j42 RunSettingsRoboTests
Change-Id: Ic9353c5ac76c0cd517318a4304fa214d6b2201d2
(cherry picked from commit ba30b04cc3)
2021-08-31 09:03:07 +00:00
Xin Li
42be0d2f75 Merge sc-dev-plus-aosp-without-vendor@7634622
Merged-In: Id2a8c43f9bca79200f837759ce9de0a6eba2a37a
Change-Id: I90fe22409ec7832714c8530f54408db747bdf3c4
2021-08-14 06:30:57 +00:00
Treehugger Robot
c156dd95fb Merge "Add owner to the connected device folder" am: 6cbb4dfbe1 am: 004f5168d4 am: f5ddc8ffaa am: 79978071e2 am: b41e35a304
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1793371

Change-Id: Ic8f5ee6abc79ea05d1b8b822ff652c466c8a9135
2021-08-12 05:45:45 +00:00
Treehugger Robot
f5ddc8ffaa Merge "Add owner to the connected device folder" am: 6cbb4dfbe1 am: 004f5168d4
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1793371

Change-Id: Ic41c5d666d0740dc8a6f4bdbb9e644ad981adee1
2021-08-12 04:54:18 +00:00
Hugh Chen
ddf63eac87 Add owner to the connected device folder
Bug: 196287361
Test: local test
Change-Id: Ib800955f04bbd6c23b9a1700faa918f8b1126d79
2021-08-12 11:16:18 +08:00