1,新增开锁成功弹窗

2,监视页面连接动画
This commit is contained in:
Daisy 2024-01-04 11:20:05 +08:00
parent db5ab63e55
commit 22bd7e01b3
4 changed files with 65 additions and 1 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 58 KiB

View File

@ -3,6 +3,7 @@ import 'package:flutter/services.dart';
import 'package:flutter_reactive_ble/flutter_reactive_ble.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
import 'package:intl/intl.dart';
import '../../../appRouters.dart';
import '../../../app_settings/app_colors.dart';
@ -490,6 +491,68 @@ class _LockDetailPageState extends State<LockDetailPage> with TickerProviderStat
}
}
//
void _showFullScreenOverlay(BuildContext context) {
showModalBottomSheet(
context: context,
isScrollControlled: true,
backgroundColor: Colors.transparent,
builder: (BuildContext context) {
return GestureDetector(
onTap: () {
Navigator.of(context).pop(); //
},
child: Container(
height: MediaQuery.of(context).size.height,
width: MediaQuery.of(context).size.width,
color: Colors.black.withOpacity(0.5),
child: Stack(
alignment: Alignment.center,
children: [
Image.asset(
'images/main/unlocked_bg.png',
width: 358.w,
height: 348.h,
),
Positioned(
top: ScreenUtil().screenHeight / 2 - 10.h,
child: Column(
children: [
Text(
widget.lockListInfoItemEntity.lockAlias!,
style: TextStyle(
color: AppColors.placeholderTextColor,
fontSize: 26.sp),
),
SizedBox(
height: 10.h,
),
Text(
getCurrentFormattedTime(),
style: TextStyle(
color: AppColors.darkGrayTextColor,
fontSize: 26.sp),
)
],
))
],
),
),
);
},
);
}
String getCurrentFormattedTime() {
//
DateTime now = DateTime.now();
//
String formattedTime = DateFormat('MM/dd HH:mm').format(now);
return formattedTime;
}
@override
void didChangeDependencies() {
// TODO: implement didChangeDependencies

View File

@ -26,7 +26,7 @@ class _RealTimePicturePageState extends State<RealTimePicturePage>
// listeningAnimations();
state.animationController =
AnimationController(duration: const Duration(seconds: 2), vsync: this);
AnimationController(duration: const Duration(seconds: 1), vsync: this);
state.animationController.repeat();
//StatusListener
state.animationController.addStatusListener((status) {

View File

@ -128,6 +128,7 @@ dependencies:
# ffmpeg_kit_flutter: 5.1.0-LTS
fast_gbk: ^1.0.0
flutter_pcm_sound: ^1.1.0
intl: ^0.18.1
# flutter_audio_capture: <1.1.5
flutter_voice_processor: ^1.1.0