diff --git a/Modules/BluetoothPanel/BluetoothPanel.qml b/Modules/BluetoothPanel/BluetoothPanel.qml index fa65dfc..ac78db3 100644 --- a/Modules/BluetoothPanel/BluetoothPanel.qml +++ b/Modules/BluetoothPanel/BluetoothPanel.qml @@ -75,7 +75,7 @@ NPanel { } Rectangle { - visible: !Settings.data.network.bluetoothEnabled + visible: !(BluetoothService.adapter && BluetoothService.adapter.enabled) Layout.fillWidth: true Layout.fillHeight: true color: Color.transparent diff --git a/Services/BluetoothService.qml b/Services/BluetoothService.qml index 9bbc55b..cfdb5a7 100644 --- a/Services/BluetoothService.qml +++ b/Services/BluetoothService.qml @@ -32,6 +32,16 @@ Singleton { function init() { Logger.log("Bluetooth", "Service initialized") + delaySyncState.running = true + } + + Timer { + id: delaySyncState + interval: 1000 + repeat: false + onTriggered: { + Settings.data.network.bluetoothEnabled = adapter.enabled + } } Timer {