opt: replyReplyPanel

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-05-09 13:24:14 +08:00
parent 2d75d89825
commit efaff0ae79
4 changed files with 19 additions and 10 deletions

View File

@@ -163,9 +163,10 @@ class _ArticlePageState extends State<ArticlePage>
EasyThrottle.throttle('replyReply', const Duration(milliseconds: 500), () {
int oid = replyItem.oid.toInt();
int rpid = replyItem.id.toInt();
Widget replyReplyPage(
[bool automaticallyImplyLeading = true,
VoidCallback? onDispose]) =>
Widget replyReplyPage({
bool automaticallyImplyLeading = true,
VoidCallback? onDispose,
}) =>
Scaffold(
resizeToAvoidBottomInset: false,
appBar: AppBar(
@@ -177,6 +178,7 @@ class _ArticlePageState extends State<ArticlePage>
top: false,
bottom: false,
child: VideoReplyReplyPanel(
enableSlide: false,
id: id,
oid: oid,
rpid: rpid,
@@ -208,8 +210,8 @@ class _ArticlePageState extends State<ArticlePage>
context: context,
removeLeft: true,
child: replyReplyPage(
false,
() {
automaticallyImplyLeading: false,
onDispose: () {
if (isFabVisible && _imageStatus != true) {
_showFab();
}

View File

@@ -161,9 +161,10 @@ class _DynamicDetailPageState extends State<DynamicDetailPage>
EasyThrottle.throttle('replyReply', const Duration(milliseconds: 500), () {
int oid = replyItem.oid.toInt();
int rpid = replyItem.id.toInt();
Widget replyReplyPage(
[bool automaticallyImplyLeading = true,
VoidCallback? onDispose]) =>
Widget replyReplyPage({
bool automaticallyImplyLeading = true,
VoidCallback? onDispose,
}) =>
Scaffold(
resizeToAvoidBottomInset: false,
appBar: AppBar(
@@ -175,6 +176,7 @@ class _DynamicDetailPageState extends State<DynamicDetailPage>
top: false,
bottom: false,
child: VideoReplyReplyPanel(
enableSlide: false,
id: id,
oid: oid,
rpid: rpid,
@@ -206,8 +208,8 @@ class _DynamicDetailPageState extends State<DynamicDetailPage>
context: context,
removeLeft: true,
child: replyReplyPage(
false,
() {
automaticallyImplyLeading: false,
onDispose: () {
if (isFabVisible && _imageStatus != true) {
_showFab();
}

View File

@@ -21,6 +21,7 @@ import 'package:scrollable_positioned_list/scrollable_positioned_list.dart';
class VideoReplyReplyPanel extends CommonSlidePage {
const VideoReplyReplyPanel({
super.key,
super.enableSlide,
this.id,
required this.oid,
required this.rpid,

View File

@@ -136,6 +136,7 @@ class PiliScheme {
top: false,
bottom: false,
child: VideoReplyReplyPanel(
enableSlide: false,
oid: int.parse(oid),
rpid: rpid,
source: 'routePush',
@@ -278,6 +279,7 @@ class PiliScheme {
top: false,
bottom: false,
child: VideoReplyReplyPanel(
enableSlide: false,
oid: oid,
rpid: rootId,
id: rpId,
@@ -328,6 +330,7 @@ class PiliScheme {
top: false,
bottom: false,
child: VideoReplyReplyPanel(
enableSlide: false,
oid: oid,
rpid: rpId,
source: 'routePush',
@@ -392,6 +395,7 @@ class PiliScheme {
top: false,
bottom: false,
child: VideoReplyReplyPanel(
enableSlide: false,
oid: oid ?? int.parse(dynId),
rpid: rpid,
source: 'routePush',