fix: floating未销毁导致日志出现bad state: Cannot add event after closing

This commit is contained in:
orz12
2024-02-17 13:30:54 +08:00
parent 31273d81fe
commit cda2acc4ca

View File

@@ -55,6 +55,11 @@ class _HeaderControlState extends State<HeaderControl> {
speedsList = widget.controller!.speedsList;
}
@override
void dispose() {
widget.floating?.dispose();
super.dispose();
}
/// 设置面板
void showSettingSheet() {
showModalBottomSheet(
@@ -656,7 +661,7 @@ class _HeaderControlState extends State<HeaderControl> {
margin: const EdgeInsets.all(12),
child: Column(
children: [
SizedBox(
const SizedBox(
height: 45,
child: Center(child: Text('选择解码格式', style: titleStyle))),
Expanded(