style:去除多余代码

This commit is contained in:
liyi 2025-04-16 14:13:50 +08:00
parent 204affd6b1
commit 7f2d591e67

View File

@ -449,50 +449,6 @@ class NearbyLockLogic extends BaseGetXController {
}
}
/// 128-bit UUID
bool isPaired128Bit(String serviceUuid) {
if (serviceUuid.length != 36) return false; // 128-bit UUID
try {
String status = serviceUuid.substring(30, 32); // 31 32
return status == '01'; // '01'
} catch (e) {
return false; // false
}
}
/// 128-bit UUID
bool isSleeping128Bit(String serviceUuid) {
if (serviceUuid.length != 36) return false; // 128-bit UUID
try {
String status = serviceUuid.substring(32, 34); // 33 34
return status == '00'; // '00'
} catch (e) {
return false; // false
}
}
/// 32-bit UUID
bool isPaired32Bit(String serviceUuid) {
if (serviceUuid.length != 8) return false; // 32-bit UUID
try {
String status = serviceUuid.substring(3, 5); // 4 5
return status == '01'; // '01'
} catch (e) {
return false; // false
}
}
/// 32-bit UUID
bool isSleeping32Bit(String serviceUuid) {
if (serviceUuid.length != 8) return false; // 32-bit UUID
try {
String status = serviceUuid.substring(5, 7); // 6 7
return status == '00'; // '00'
} catch (e) {
return false; // false
}
}
void stopScanBlueList() {
BlueManage().disconnect();
BlueManage().stopScan();