Making Bluetooth accessible without user confirmation
1 answer
Study
I started researching the answer for you by reading about the enable () method. See "Setting up Bluetooth" , then # 2. It says:
Enabling Discoverability contains a lot of information that can be useful for preserving the DRY code or creating a workaround.
Answer
According to the documentation, when a device is detected, a pop-up will always be displayed to confirm the user.
The workaround provided by Android is not to detect the device at all:
+4
source to share