Use media_kit only for live/motion photos
This commit is contained in:
parent
9b81dde9e4
commit
543f73c33b
1 changed files with 8 additions and 8 deletions
|
@ -2,7 +2,7 @@ import 'package:flutter/material.dart';
|
||||||
import 'package:logging/logging.dart';
|
import 'package:logging/logging.dart';
|
||||||
import 'package:photos/models/file/file.dart';
|
import 'package:photos/models/file/file.dart';
|
||||||
import 'package:photos/models/file/file_type.dart';
|
import 'package:photos/models/file/file_type.dart';
|
||||||
import "package:photos/ui/viewer/file/video_widget_new.dart";
|
import "package:photos/ui/viewer/file/video_widget.dart";
|
||||||
import "package:photos/ui/viewer/file/zoomable_live_image_new.dart";
|
import "package:photos/ui/viewer/file/zoomable_live_image_new.dart";
|
||||||
|
|
||||||
class FileWidget extends StatelessWidget {
|
class FileWidget extends StatelessWidget {
|
||||||
|
@ -38,16 +38,16 @@ class FileWidget extends StatelessWidget {
|
||||||
key: key ?? ValueKey(fileKey),
|
key: key ?? ValueKey(fileKey),
|
||||||
);
|
);
|
||||||
} else if (file.fileType == FileType.video) {
|
} else if (file.fileType == FileType.video) {
|
||||||
// return VideoWidget(
|
return VideoWidget(
|
||||||
// file,
|
|
||||||
// autoPlay: autoPlay ?? false, // Autoplay if it was opened directly
|
|
||||||
// tagPrefix: tagPrefix,
|
|
||||||
// playbackCallback: playbackCallback,
|
|
||||||
// );
|
|
||||||
return VideoWidgetNew(
|
|
||||||
file,
|
file,
|
||||||
|
autoPlay: autoPlay ?? false, // Autoplay if it was opened directly
|
||||||
tagPrefix: tagPrefix,
|
tagPrefix: tagPrefix,
|
||||||
|
playbackCallback: playbackCallback,
|
||||||
);
|
);
|
||||||
|
// return VideoWidgetNew(
|
||||||
|
// file,
|
||||||
|
// tagPrefix: tagPrefix,
|
||||||
|
// );
|
||||||
} else {
|
} else {
|
||||||
Logger('FileWidget').severe('unsupported file type ${file.fileType}');
|
Logger('FileWidget').severe('unsupported file type ${file.fileType}');
|
||||||
return const Icon(Icons.error);
|
return const Icon(Icons.error);
|
||||||
|
|
Loading…
Add table
Reference in a new issue