1.蓝牙传输文件的存储路径:

      原生的路径是String root = Environment.getExternalStorageDirectory().getPath(); 会直接存储到内部存储器中。将它改成String root = StorageManagerEx.getDefaultPath() +"/";即可。这样传输文件会存储到当前的主存储器。

     代码路径是/packages/apps/Bluetooth / src/com/android/bluetooth/opp/BluetoothOppReceiveFileInfo.java

2.接收蓝牙文件通知没有亮屏解决办法:

    在发送通知的地方加上:

   PowerManager pm = (PowerManager)mContext.getSystemService(Context.POWER_SERVICE);

  lock.acquire(1000);

代码路径:packages/apps/Bluetooth / src/com/android/bluetooth/opp/BluetoothOppNotification.java-updateIncomingFileConfirmNotification()

相关文章:

  • 2021-12-30
  • 2021-12-06
  • 2021-12-29
  • 2022-02-07
  • 2022-12-23
  • 2022-12-23
  • 2021-12-22
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-04
  • 2021-05-30
  • 2022-12-23
  • 2021-10-27
相关资源
相似解决方案