π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Restore original formatting snippets
Prateek Sunal25388a3fa43a
diff --git a/mobile/apps/photos/lib/ui/tools/editor/video_editor_page.dart b/mobile/apps/photos/lib/ui/tools/editor/video_editor_page.dartindex 7333bf47ee..34469aca7a 100644--- a/mobile/apps/photos/lib/ui/tools/editor/video_editor_page.dart+++ b/mobile/apps/photos/lib/ui/tools/editor/video_editor_page.dart@@ -96,23 +96,23 @@ class _VideoEditorPageState extends State<VideoEditorPage> {),);- _controller!- .initialize()- .then((_) {- // Apply metadata rotation to the video player- if (_quarterTurnsForRotationCorrection != null &&- _quarterTurnsForRotationCorrection! != 0) {- final rotationDegrees = _quarterTurnsForRotationCorrection! * 90;- _controller!.video.value = _controller!.video.value.copyWith(- rotationCorrection: rotationDegrees,- );- }- setState(() {});- })- .catchError((error) {- // handle minumum duration bigger than video duration error- Navigator.pop(context);- }, test: (e) => e is VideoMinDurationError);+ _controller!.initialize().then((_) {+ // Apply metadata rotation to the video player+ if (_quarterTurnsForRotationCorrection != null &&+ _quarterTurnsForRotationCorrection! != 0) {+ final rotationDegrees = _quarterTurnsForRotationCorrection! * 90;+ _controller!.video.value = _controller!.video.value.copyWith(+ rotationCorrection: rotationDegrees,+ );+ }+ setState(() {});+ }).catchError(+ (error) {+ // handle minumum duration bigger than video duration error+ Navigator.pop(context);+ },+ test: (e) => e is VideoMinDurationError,+ );});}@@ -139,8 +139,7 @@ class _VideoEditorPageState extends State<VideoEditorPage> {child: ValueListenableBuilder<bool>(valueListenable: _isExporting,builder: (context, isExporting, _) {- final isReady =- _controller != null &&+ final isReady = _controller != null &&_controller!.initialized &&_quarterTurnsForRotationCorrection != null;@@ -207,7 +206,8 @@ class _VideoEditorPageState extends State<VideoEditorPage> {children: [Text("Native (i)",- style: getEnteTextTheme(context).mini+ style: getEnteTextTheme(context)+ .mini.copyWith(color: colorScheme.textMuted),),const SizedBox(width: 4),@@ -236,7 +236,9 @@ class _VideoEditorPageState extends State<VideoEditorPage> {svgPath:"assets/video-editor/video-editor-trim-action.svg",onPressed: () => _openSubEditor(- VideoTrimPage(controller: _controller!),+ VideoTrimPage(+ controller: _controller!,+ ),),),const SizedBox(width: 24),@@ -245,7 +247,9 @@ class _VideoEditorPageState extends State<VideoEditorPage> {svgPath:"assets/video-editor/video-editor-crop-action.svg",onPressed: () => _openSubEditor(- VideoCropPage(controller: _controller!),+ VideoCropPage(+ controller: _controller!,+ ),),),const SizedBox(width: 24),@@ -254,7 +258,9 @@ class _VideoEditorPageState extends State<VideoEditorPage> {svgPath:"assets/video-editor/video-editor-rotate-action.svg",onPressed: () => _openSubEditor(- VideoRotatePage(controller: _controller!),+ VideoRotatePage(+ controller: _controller!,+ ),),),],@@ -670,22 +676,22 @@ class _VideoEditorPageState extends State<VideoEditorPage> {class _VideoEditorSubPageRoute extends PageRouteBuilder<void> {_VideoEditorSubPageRoute(this.child)- : super(- fullscreenDialog: true,- transitionDuration: const Duration(milliseconds: 220),- reverseTransitionDuration: const Duration(milliseconds: 180),- pageBuilder: (_, __, ___) => child,- transitionsBuilder: (_, animation, __, child) {- return FadeTransition(- opacity: CurvedAnimation(- parent: animation,- curve: Curves.easeOutCubic,- reverseCurve: Curves.easeInCubic,- ),- child: child,- );- },- );+ : super(+ fullscreenDialog: true,+ transitionDuration: const Duration(milliseconds: 220),+ reverseTransitionDuration: const Duration(milliseconds: 180),+ pageBuilder: (_, __, ___) => child,+ transitionsBuilder: (_, animation, __, child) {+ return FadeTransition(+ opacity: CurvedAnimation(+ parent: animation,+ curve: Curves.easeOutCubic,+ reverseCurve: Curves.easeInCubic,+ ),+ child: child,+ );+ },+ );final Widget child;}