mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
@@ -81,17 +81,10 @@ class _DynamicsTabPageState
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
super.build(context);
|
||||
// debugPrint(widget.dynamicsType + widget.mid.value.toString());
|
||||
return refreshIndicator(
|
||||
// key:
|
||||
// ValueKey<String>(widget.dynamicsType + widget.mid.value.toString()),
|
||||
onRefresh: () async {
|
||||
dynamicsWaterfallFlow = GStorage.setting
|
||||
.get(SettingBoxKey.dynamicsWaterfallFlow, defaultValue: true);
|
||||
await Future.wait([
|
||||
controller.onRefresh(),
|
||||
dynamicsController.queryFollowUp(),
|
||||
]);
|
||||
dynamicsController.queryFollowUp();
|
||||
await controller.onRefresh();
|
||||
},
|
||||
child: CustomScrollView(
|
||||
physics: const AlwaysScrollableScrollPhysics(),
|
||||
|
||||
@@ -32,10 +32,11 @@ class _SearchDynamicState extends State<SearchDynamic>
|
||||
return Obx(() => _buildBody(context, widget.ctr.dynamicState.value));
|
||||
}
|
||||
|
||||
late final bool dynamicsWaterfallFlow = GStorage.setting
|
||||
.get(SettingBoxKey.dynamicsWaterfallFlow, defaultValue: true);
|
||||
|
||||
Widget _buildBody(BuildContext context,
|
||||
LoadingState<List<DynamicItemModel>?> loadingState) {
|
||||
bool dynamicsWaterfallFlow = GStorage.setting
|
||||
.get(SettingBoxKey.dynamicsWaterfallFlow, defaultValue: true);
|
||||
return switch (loadingState) {
|
||||
Loading() => loadingWidget,
|
||||
Success() => loadingState.response?.isNotEmpty == true
|
||||
|
||||
Reference in New Issue
Block a user