mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-08-14 10:10:16 +00:00
Settings BT: fix toggle not reactive if no BT adapter
This commit is contained in:
@@ -69,8 +69,9 @@ ColumnLayout {
|
||||
description: "Turn Bluetooth radio on or off"
|
||||
value: Settings.settings.bluetoothEnabled
|
||||
onToggled: function() {
|
||||
Settings.settings.bluetoothEnabled = !Settings.settings.bluetoothEnabled;
|
||||
if (Bluetooth.defaultAdapter) {
|
||||
Settings.settings.bluetoothEnabled = !Settings.settings.bluetoothEnabled;
|
||||
|
||||
Bluetooth.defaultAdapter.enabled = Settings.settings.bluetoothEnabled;
|
||||
if (Bluetooth.defaultAdapter.enabled)
|
||||
Bluetooth.defaultAdapter.discovering = true;
|
||||
|
||||
Reference in New Issue
Block a user