Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 272124ef authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Replace hidden Iothread with new Thread" am: c16fcd76 am: c6c40e9c...

Merge "Replace hidden Iothread with new Thread" am: c16fcd76 am: c6c40e9c am: 0e3a8597 am: 40b0b192

Original change: https://android-review.googlesource.com/c/platform/packages/modules/Bluetooth/+/1965087

Change-Id: Iae7e49474b9ff40b8b4977cd5e9c84fba5c08e73
parents 83fa22ae 40b0b192
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -60,6 +60,7 @@ import android.database.ContentObserver;
import android.os.Binder;
import android.os.Bundle;
import android.os.Handler;
import android.os.HandlerThread;
import android.os.IBinder;
import android.os.Looper;
import android.os.Message;
@@ -267,6 +268,7 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
            new ConcurrentHashMap<IBinder, ClientDeathRecipient>();

    private int mState;
    private final HandlerThread mBluetoothHandlerThread;
    private final BluetoothHandler mHandler;
    private int mErrorRecoveryRetryCounter;
    private final int mSystemUiUid;
@@ -482,7 +484,10 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
    };

    BluetoothManagerService(Context context) {
        mHandler = new BluetoothHandler(IoThread.get().getLooper());
        mBluetoothHandlerThread = new HandlerThread("BluetoothManagerService");
        mBluetoothHandlerThread.start();

        mHandler = new BluetoothHandler(mBluetoothHandlerThread.getLooper());

        mContext = context;

@@ -558,7 +563,7 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
        if (airplaneModeRadios == null || airplaneModeRadios.contains(
                Settings.Global.RADIO_BLUETOOTH)) {
            mBluetoothAirplaneModeListener = new BluetoothAirplaneModeListener(
                    this, IoThread.get().getLooper(), context);
                    this, mBluetoothHandlerThread.getLooper(), context);
        }

        int systemUiUid = -1;