From c925ed211700a8c76c0e2af28c5569fbf302f51c Mon Sep 17 00:00:00 2001 From: Prateek Sunal Date: Thu, 10 Jul 2025 18:52:46 +0530 Subject: [PATCH] fix: issues --- .../machine_learning/face_thumbnail_generator.dart | 3 --- .../apps/photos/lib/ui/collections/album/row_item.dart | 4 ++-- .../photos/lib/ui/home/memories/full_screen_memory.dart | 2 +- .../photos/lib/ui/home/memories/memory_cover_widget.dart | 4 ++-- .../ui/viewer/search/result/people_section_all_page.dart | 9 ++++++--- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/mobile/apps/photos/lib/services/machine_learning/face_thumbnail_generator.dart b/mobile/apps/photos/lib/services/machine_learning/face_thumbnail_generator.dart index 4980f2e904..2d304ce00f 100644 --- a/mobile/apps/photos/lib/services/machine_learning/face_thumbnail_generator.dart +++ b/mobile/apps/photos/lib/services/machine_learning/face_thumbnail_generator.dart @@ -1,15 +1,12 @@ import 'dart:async'; import 'dart:typed_data' show Uint8List; -import "package:computer/computer.dart"; import "package:logging/logging.dart"; import "package:photos/models/ml/face/box.dart"; import "package:photos/services/isolate_functions.dart"; import "package:photos/services/isolate_service.dart"; import "package:photos/utils/image_ml_util.dart"; -final Computer _computer = Computer.shared(); - class FaceThumbnailGenerator extends SuperIsolate { @override Logger get logger => _logger; diff --git a/mobile/apps/photos/lib/ui/collections/album/row_item.dart b/mobile/apps/photos/lib/ui/collections/album/row_item.dart index ffaaf04421..ddc6fb5721 100644 --- a/mobile/apps/photos/lib/ui/collections/album/row_item.dart +++ b/mobile/apps/photos/lib/ui/collections/album/row_item.dart @@ -120,8 +120,8 @@ class AlbumRowItemWidget extends StatelessWidget { child: isSelected ? ColorFiltered( colorFilter: ColorFilter.mode( - Colors.black.withOpacity( - 0.4, + Colors.black.withValues( + alpha: 0.4, ), BlendMode.darken, ), diff --git a/mobile/apps/photos/lib/ui/home/memories/full_screen_memory.dart b/mobile/apps/photos/lib/ui/home/memories/full_screen_memory.dart index 0fa74931a8..4813534190 100644 --- a/mobile/apps/photos/lib/ui/home/memories/full_screen_memory.dart +++ b/mobile/apps/photos/lib/ui/home/memories/full_screen_memory.dart @@ -335,7 +335,7 @@ class _FullScreenMemoryState extends State { currentIndex: value, selectedColor: Colors.white, unselectedColor: - Colors.white.withOpacity(0.4), + Colors.white.withValues(alpha: 0.4), duration: duration, animationController: (controller) { _progressAnimationController = controller; diff --git a/mobile/apps/photos/lib/ui/home/memories/memory_cover_widget.dart b/mobile/apps/photos/lib/ui/home/memories/memory_cover_widget.dart index 16665f6b2d..d4292ffdb4 100644 --- a/mobile/apps/photos/lib/ui/home/memories/memory_cover_widget.dart +++ b/mobile/apps/photos/lib/ui/home/memories/memory_cover_widget.dart @@ -115,7 +115,7 @@ class _MemoryCoverWidgetState extends State { decoration: BoxDecoration( gradient: LinearGradient( colors: [ - Colors.black.withOpacity(0.5), + Colors.black.withValues(alpha: 0.5), Colors.transparent, ], stops: const [0, 1], @@ -171,7 +171,7 @@ class _MemoryCoverWidgetState extends State { decoration: BoxDecoration( gradient: LinearGradient( colors: [ - Colors.black.withOpacity(0.5), + Colors.black.withValues(alpha: 0.5), Colors.transparent, ], stops: const [0, 1], diff --git a/mobile/apps/photos/lib/ui/viewer/search/result/people_section_all_page.dart b/mobile/apps/photos/lib/ui/viewer/search/result/people_section_all_page.dart index d78eb4b9ba..3c6d1c9223 100644 --- a/mobile/apps/photos/lib/ui/viewer/search/result/people_section_all_page.dart +++ b/mobile/apps/photos/lib/ui/viewer/search/result/people_section_all_page.dart @@ -212,8 +212,8 @@ class SelectablePersonSearchExample extends StatelessWidget { ), child: ColorFiltered( colorFilter: ColorFilter.mode( - Colors.black.withOpacity( - isSelected ? 0.4 : 0, + Colors.black.withValues( + alpha: isSelected ? 0.4 : 0, ), BlendMode.darken, ), @@ -568,7 +568,10 @@ class _PeopleSectionAllWidgetState extends State { shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(8), side: BorderSide( - color: Theme.of(context).colorScheme.outline.withOpacity(0.3), + color: Theme.of(context) + .colorScheme + .outline + .withValues(alpha: 0.3), width: 1, ), ),