Hides controls when video starts and fixes placeholder for memory card
Remove prints
This commit is contained in:
@@ -96,14 +96,12 @@ class _ChewieControllerHookState
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
void initHook() async {
|
void initHook() async {
|
||||||
print('CHEWIE CONTROLLER > creating chewie $hashCode');
|
|
||||||
super.initHook();
|
super.initHook();
|
||||||
_initialize().whenComplete(() => setState(() {}));
|
_initialize().whenComplete(() => setState(() {}));
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void dispose() {
|
void dispose() {
|
||||||
print('CHEWIE CONTROLLER > disposing chewie $hashCode');
|
|
||||||
videoPlayerController?.pause();
|
videoPlayerController?.pause();
|
||||||
videoPlayerController?.dispose();
|
videoPlayerController?.dispose();
|
||||||
chewieController?.dispose();
|
chewieController?.dispose();
|
||||||
|
|||||||
@@ -110,6 +110,9 @@ class VideoViewerPage extends HookConsumerWidget {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Hide the controls
|
||||||
|
ref.read(showControlsProvider.notifier).show = false;
|
||||||
|
|
||||||
final video = controller.videoPlayerController.value;
|
final video = controller.videoPlayerController.value;
|
||||||
|
|
||||||
// Hold initial volume
|
// Hold initial volume
|
||||||
|
|||||||
@@ -72,9 +72,11 @@ class MemoryCard extends StatelessWidget {
|
|||||||
key: ValueKey(asset),
|
key: ValueKey(asset),
|
||||||
asset: asset,
|
asset: asset,
|
||||||
showDownloadingIndicator: false,
|
showDownloadingIndicator: false,
|
||||||
placeholder: ImmichImage(
|
placeholder: SizedBox.expand(
|
||||||
asset,
|
child: ImmichImage(
|
||||||
fit: fit,
|
asset,
|
||||||
|
fit: fit,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
hideControlsTimer: const Duration(seconds: 2),
|
hideControlsTimer: const Duration(seconds: 2),
|
||||||
onVideoEnded: onVideoEnded,
|
onVideoEnded: onVideoEnded,
|
||||||
|
|||||||
Reference in New Issue
Block a user