PhonePolicy: Stop auto connecting to devices that failed to connect

* Set priority from AUTO_CONNECT to ON when device failed to connect
  as indicated by transition from CONNECTING TO DISCONNECTED state
* Set priority from AUTO_CONNECT to ON for all disconnected devices
  when a device is connected

Bug: 79956685
Test: runtest -j40 bluetooth -c
      com.android.bluetooth.btservice.PhonePolicyTest
Change-Id: I319ee174fa5f32630418c40f8372e30d41ae8871
(cherry picked from commit d5fcc13ca66d1eabeee0e6f9a6daeabbdc6b7573)
2 files changed