This commit is contained in:
魏少阳 2024-04-20 10:09:19 +08:00
commit b369a9db3f
2 changed files with 11 additions and 44 deletions

View File

@ -50,7 +50,7 @@ class _LockMonitoringPageState extends State<LockMonitoringPage> {
child: Container(
width: 1.sw,
height: 1.sh,
// color: Colors.white,
color: Colors.transparent,
child: Stack(
children: [
Image.memory(
@ -58,28 +58,12 @@ class _LockMonitoringPageState extends State<LockMonitoringPage> {
gaplessPlayback: true,
width: 1.sw,
height: 1.sh,
fit: BoxFit.cover,
fit: BoxFit.none,
filterQuality: FilterQuality.high,
errorBuilder: (context, error, stackTrace) {
return Container(color: Colors.transparent);
},
),
// Obx(() {
// if (state.listPhotoData.value.isEmpty ||
// state.listPhotoData.value.length < 10) {
// return Container(color: Colors.transparent);
// } else {
// return Image.memory(
// state.listPhotoData.value,
// gaplessPlayback: true,
// width: 1.sw,
// height: 1.sh,
// fit: BoxFit.cover,
// errorBuilder: (context, error, stackTrace) {
// return Container(color: Colors.transparent);
// },
// );
// }
// }),
Positioned(
top: ScreenUtil().statusBarHeight + 30.h,
width: 1.sw,
@ -96,23 +80,6 @@ class _LockMonitoringPageState extends State<LockMonitoringPage> {
Text("$min:$sec",
style: TextStyle(
fontSize: 26.sp, color: Colors.white)),
// SizedBox(width: 30.w),
// GestureDetector(
// onTap: () {
// Get.back();
// },
// child: Container(
// decoration: BoxDecoration(
// color: Colors.white,
// borderRadius: BorderRadius.circular(25.h)),
// padding: EdgeInsets.all(10.w),
// child: Image(
// width: 40.w,
// height: 40.w,
// image: const AssetImage("images/icon_left_black.png"),
// ),
// ),
// ),
]);
}),
),

View File

@ -42,15 +42,15 @@ class UDPManage {
int remoteUnlock = 0; // 1 0
void initUdp() async {
if (host != '') {
var listAddress = InternetAddress.lookup(host);
listAddress.then((list) {
list.forEach((element) {
// print('Udp ----> element.address:${element.address} element.host:${element.host}');
host = element.address;
});
// if (host != '') {
var listAddress = InternetAddress.lookup(host);
listAddress.then((list) {
list.forEach((element) {
// print('Udp ----> element.address:${element.address} element.host:${element.host}');
host = element.address;
});
}
});
// }
await _initUdp();
}