fix:切换播放问题
This commit is contained in:
parent
ab042840b9
commit
def8b49505
@ -1,5 +1,6 @@
|
||||
import 'package:easy_refresh/easy_refresh.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_kinetra/kt_pages/kt_main_page/view.dart';
|
||||
import 'package:flutter_kinetra/kt_utils/kt_string_extend.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:get/get.dart';
|
||||
@ -28,6 +29,7 @@ class _KtExplorePageState extends State<KtExplorePage>
|
||||
super.build(context);
|
||||
return GetBuilder<KtExploreLogic>(
|
||||
builder: (ctrl) {
|
||||
if(Get.find<KtMainLogic>().curIndex != 1) return Container();
|
||||
if (state.loadStatus == KtLoadStatusType.loadNoData ||
|
||||
state.loadStatus == KtLoadStatusType.loadFailed) {
|
||||
return KtStatusWidget(
|
||||
|
@ -1,6 +1,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_kinetra/kt_pages/kt_actor/kt_actor_page.dart';
|
||||
import 'package:flutter_kinetra/kt_pages/kt_explore/logic.dart';
|
||||
import 'package:flutter_kinetra/kt_utils/kt_string_extend.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:get/get.dart';
|
||||
@ -110,8 +111,13 @@ class _KtMainPageState extends State<KtMainPage>
|
||||
_currentIndex = index;
|
||||
logic.curIndex = index;
|
||||
_controller.jumpToPage(index);
|
||||
if (index == 3) {
|
||||
final myListLogic = Get.put(MyListLogic());
|
||||
myListLogic.initData();
|
||||
} else if (index == 1) {
|
||||
final exploreLogic = Get.put(KtExploreLogic());
|
||||
exploreLogic.update();
|
||||
}
|
||||
},
|
||||
items: [
|
||||
..._tabsTitle.map(
|
||||
@ -139,7 +145,7 @@ class _KtMainPageState extends State<KtMainPage>
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
},
|
||||
),
|
||||
);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user