Merge remote-tracking branch 'origin/flutter-upgrade' into isolated-ffmpeg

This commit is contained in:
Prateek Sunal
2025-07-10 18:53:46 +05:30
8 changed files with 20 additions and 14 deletions

View File

@@ -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;

View File

@@ -3,7 +3,6 @@ import "dart:io" show File;
import "package:flutter/cupertino.dart";
import "package:flutter/foundation.dart" show kDebugMode;
import "package:flutter/material.dart" show BuildContext;
import "package:logging/logging.dart";
import "package:path_provider/path_provider.dart";
import "package:photos/core/event_bus.dart";

View File

@@ -27,7 +27,7 @@ class AlbumRowItemWidget extends StatelessWidget {
final SelectedAlbums? selectedAlbums;
static const _borderWidth = 1.0;
static const _cornerRadius = 12.0;
static const _cornerSmoothing = 1.0;
static const _cornerSmoothing = 0.6;
const AlbumRowItemWidget(
this.c,
@@ -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,
),

View File

@@ -13,7 +13,7 @@ class DeviceFolderItem extends StatelessWidget {
final double sideOfThumbnail;
static const _cornerRadius = 12.0;
static const _cornerSmoothing = 1.0;
static const _cornerSmoothing = 0.6;
static const _borderWidth = 1.0;
const DeviceFolderItem(

View File

@@ -4,6 +4,7 @@ import 'dart:math';
import 'package:flutter/material.dart';
import "package:flutter/services.dart";
import "package:logging/logging.dart";
import "package:photos/core/configuration.dart";
import "package:photos/core/event_bus.dart";
import "package:photos/events/clear_album_selections_event.dart";
import "package:photos/generated/l10n.dart";
@@ -98,10 +99,16 @@ class _CollectionsFlexiGridViewWidgetState
Future<void> _navigateToCollectionPage(Collection c) async {
final thumbnail = await CollectionsService.instance.getCover(c);
final bool isOwner = c.isOwner(Configuration.instance.getUserID()!);
final String tagPrefix = (isOwner ? "collection" : "shared_collection") +
widget.tag +
"_" +
c.id.toString();
// ignore: unawaited_futures
routeToPage(
context,
CollectionPage(
tagPrefix: tagPrefix,
CollectionWithThumbnail(c, thumbnail),
),
);

View File

@@ -335,7 +335,7 @@ class _FullScreenMemoryState extends State<FullScreenMemory> {
currentIndex: value,
selectedColor: Colors.white,
unselectedColor:
Colors.white.withOpacity(0.4),
Colors.white.withValues(alpha: 0.4),
duration: duration,
animationController: (controller) {
_progressAnimationController = controller;

View File

@@ -115,7 +115,7 @@ class _MemoryCoverWidgetState extends State<MemoryCoverWidget> {
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<MemoryCoverWidget> {
decoration: BoxDecoration(
gradient: LinearGradient(
colors: [
Colors.black.withOpacity(0.5),
Colors.black.withValues(alpha: 0.5),
Colors.transparent,
],
stops: const [0, 1],

View File

@@ -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<PeopleSectionAllWidget> {
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,
),
),