Cleanup: use lambda instead of runnable.

This commit is contained in:
Dennis Guse
2020-06-09 23:01:09 +02:00
parent accb30152f
commit a3ba1e1490
14 changed files with 89 additions and 203 deletions
@@ -61,13 +61,10 @@ public class BluetoothUtils {
final Object mutex = new Object();
Handler handler = new Handler(Looper.getMainLooper());
handler.post(new Runnable() {
@Override
public void run() {
adapters.add(BluetoothAdapter.getDefaultAdapter());
synchronized (mutex) {
mutex.notify();
}
handler.post(() -> {
adapters.add(BluetoothAdapter.getDefaultAdapter());
synchronized (mutex) {
mutex.notify();
}
});