* fix: 1080p

* opt: import export

* opt: downloader

* opt: skeleton

* opt: parseColor

* tweak

* opt: sb seek

* opt: rxn
This commit is contained in:
My-Responsitories
2026-05-08 12:50:43 +00:00
committed by dom
parent 07843a5e77
commit b7bd516aa7
28 changed files with 253 additions and 370 deletions

View File

@@ -741,8 +741,8 @@ class VideoDetailController extends GetxController
bool isQuerying = false;
final Rx<List<LanguageItem>?> languages = Rx<List<LanguageItem>?>(null);
final Rx<String?> currLang = Rx<String?>(null);
final languages = Rxn<List<LanguageItem>>();
final currLang = Rxn<String>();
void setLanguage(String language) {
if (currLang.value == language) return;
if (!isLoginVideo) {

View File

@@ -467,14 +467,21 @@ class _PostPanelState extends State<PostPanel>
final player = plPlayerController.videoPlayerController;
if (player != null) {
final start = (item.segment.first * 1000).round();
Future<void> seekTo() => player.seek(
Duration(milliseconds: (item.segment.second * 1000).round()),
);
if (start <= 0) {
seekTo();
if (!player.state.playing) {
await player.play();
}
return;
}
final seek = max(0, start - 2000);
await player.seek(Duration(milliseconds: seek));
if (!player.state.playing) {
await player.play();
}
Future<void> seekTo() => player.seek(
Duration(milliseconds: (item.segment.second * 1000).round()),
);
if (start > seek) {
final posSub = player.stream.position.listen(
null,

View File

@@ -32,7 +32,7 @@ class VideoReplyReplyController extends ReplyController
int replyType;
bool hasRoot = false;
final Rx<ReplyInfo?> firstFloor = Rx(null);
final firstFloor = Rxn<ReplyInfo>();
final index = RxnInt();

View File

@@ -645,7 +645,10 @@ class HeaderControlState extends State<HeaderControl>
onTap: () async {
Get.back();
try {
final result = await FilePicker.pickFiles();
final result = await FilePicker.pickFiles(
type: .custom,
allowedExtensions: const ['json', 'vtt', 'srt'],
);
if (result != null) {
final file = result.files.single;
final path = file.path;