mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
refactor: related
This commit is contained in:
@@ -102,15 +102,10 @@ class _HotPageState extends State<HotPage> with AutomaticKeepAliveClientMixin {
|
||||
);
|
||||
}
|
||||
|
||||
void _removePopupDialog() {
|
||||
_hotController.popupDialog.last?.remove();
|
||||
_hotController.popupDialog.removeLast();
|
||||
}
|
||||
|
||||
OverlayEntry _createPopupDialog(videoItem) {
|
||||
return OverlayEntry(
|
||||
builder: (context) => AnimatedDialog(
|
||||
closeFn: _removePopupDialog,
|
||||
closeFn: _hotController.removePopupDialog,
|
||||
videoItem: videoItem,
|
||||
),
|
||||
);
|
||||
@@ -152,7 +147,7 @@ class _HotPageState extends State<HotPage> with AutomaticKeepAliveClientMixin {
|
||||
.add(_createPopupDialog(loadingState.response[index]));
|
||||
Overlay.of(context).insert(_hotController.popupDialog.last!);
|
||||
},
|
||||
longPressEnd: _removePopupDialog,
|
||||
longPressEnd: _hotController.removePopupDialog,
|
||||
);
|
||||
},
|
||||
childCount: loadingState.response.length,
|
||||
|
||||
Reference in New Issue
Block a user