Merge branch 'fix'

This commit is contained in:
guozhigq
2024-10-13 17:43:59 +08:00
7 changed files with 71 additions and 40 deletions

View File

@ -8,7 +8,7 @@ import 'package:pilipala/utils/storage.dart';
import '../../http/index.dart';
class HomeController extends GetxController with GetTickerProviderStateMixin {
bool flag = false;
bool flag = true;
late RxList tabs = [].obs;
RxInt initialIndex = 1.obs;
late TabController tabController;

View File

@ -1,6 +1,7 @@
import 'dart:async';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:get/get.dart';
import 'package:hive/hive.dart';
import 'package:pilipala/models/common/dynamic_badge_mode.dart';
@ -127,6 +128,14 @@ class _MainAppState extends State<MainApp> with SingleTickerProviderStateMixin {
MediaQuery.sizeOf(context).width * 9 / 16;
localCache.put('sheetHeight', sheetHeight);
localCache.put('statusBarHeight', statusBarHeight);
SystemChrome.setSystemUIOverlayStyle(
SystemUiOverlayStyle(
systemNavigationBarColor: Colors.transparent,
systemNavigationBarIconBrightness:
Get.isDarkMode ? Brightness.light : Brightness.dark,
),
);
return PopScope(
canPop: false,
onPopInvoked: (bool didPop) async {

View File

@ -675,7 +675,6 @@ class VideoDetailController extends GetxController
@override
void onClose() {
super.onClose();
plPlayerController.dispose();
tabCtr.removeListener(() {
onTabChanged();
});

View File

@ -511,6 +511,14 @@ class _VideoDetailPageState extends State<VideoDetailPage>
exitFullScreen();
}
SystemChrome.setSystemUIOverlayStyle(
SystemUiOverlayStyle(
systemNavigationBarColor: Colors.transparent,
systemNavigationBarIconBrightness:
Get.isDarkMode ? Brightness.light : Brightness.dark,
),
);
Widget buildLoadingWidget() {
return Center(child: Lottie.asset('assets/loading.json', width: 200));
}
@ -605,11 +613,6 @@ class _VideoDetailPageState extends State<VideoDetailPage>
backgroundColor: Colors.black,
elevation: 0,
scrolledUnderElevation: 0,
systemOverlayStyle: Get.isDarkMode
? SystemUiOverlayStyle.light
: snapshot.data!.toDouble() > kToolbarHeight
? SystemUiOverlayStyle.dark
: SystemUiOverlayStyle.light,
);
}),
),