π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Merge branch 'main' into placeholder_for_link
Aman Raj Singh Mouryaacf7b3a8654c
diff --cc mobile/lib/ui/viewer/actions/file_selection_actions_widget.dartindex 3fbc42ff7e,beeb9164d5..6c17ededbc--- a/mobile/lib/ui/viewer/actions/file_selection_actions_widget.dart+++ b/mobile/lib/ui/viewer/actions/file_selection_actions_widget.dart@@@ -17,9 -21,10 +21,11 @@@ import "package:photos/models/metadata/import 'package:photos/models/selected_files.dart';import 'package:photos/services/collections_service.dart';import 'package:photos/services/hidden_service.dart';+ import 'package:photos/services/machine_learning/face_ml/feedback/cluster_feedback.dart';+ import "package:photos/services/machine_learning/face_ml/person/person_service.dart";import "package:photos/theme/colors.dart";import "package:photos/theme/ente_theme.dart";+import "package:photos/ui/TEMP/show_images_prevew.dart";import 'package:photos/ui/actions/collection/collection_file_actions.dart';import 'package:photos/ui/actions/collection/collection_sharing_actions.dart';import 'package:photos/ui/collections/collection_action_sheet.dart';@@@ -651,8 -661,102 +692,103 @@@ class _FileSelectionActionsWidgetStat}}+ Future<void> _setPersonCover() async {+ final EnteFile file = widget.selectedFiles.files.first;+ await PersonService.instance.updateAttributes(+ widget.person!.remoteID,+ avatarFaceId: file.uploadedFileID.toString(),+ );+ widget.selectedFiles.clearAll();+ if (mounted) {+ setState(() => {});+ }+ Bus.instance.fire(PeopleChangedEvent());+ }++ Future<void> _onNotpersonClicked() async {+ final actionResult = await showActionSheet(+ context: context,+ buttons: [+ ButtonWidget(+ labelText: S.of(context).yesRemove,+ buttonType: ButtonType.neutral,+ buttonSize: ButtonSize.large,+ shouldStickToDarkTheme: true,+ buttonAction: ButtonAction.first,+ isInAlert: true,+ ),+ ButtonWidget(+ labelText: S.of(context).cancel,+ buttonType: ButtonType.secondary,+ buttonSize: ButtonSize.large,+ buttonAction: ButtonAction.second,+ shouldStickToDarkTheme: true,+ isInAlert: true,+ ),+ ],+ title: "Remove these photos for ${widget.person!.data.name}?",+ actionSheetType: ActionSheetType.defaultActionSheet,+ );+ if (actionResult?.action != null) {+ if (actionResult!.action == ButtonAction.first) {+ await ClusterFeedbackService.instance.removeFilesFromPerson(+ widget.selectedFiles.files.toList(),+ widget.person!,+ );+ }+ Bus.instance.fire(PeopleChangedEvent());+ }+ widget.selectedFiles.clearAll();+ if (mounted) {+ setState(() => {});+ }+ }++ Future<void> _onRemoveFromClusterClicked() async {+ if (widget.clusterID == null) {+ showShortToast(context, 'Cluster ID is null. Cannot remove files.');+ return;+ }+ final actionResult = await showActionSheet(+ context: context,+ buttons: [+ ButtonWidget(+ labelText: S.of(context).yesRemove,+ buttonType: ButtonType.neutral,+ buttonSize: ButtonSize.large,+ shouldStickToDarkTheme: true,+ buttonAction: ButtonAction.first,+ isInAlert: true,+ ),+ ButtonWidget(+ labelText: S.of(context).cancel,+ buttonType: ButtonType.secondary,+ buttonSize: ButtonSize.large,+ buttonAction: ButtonAction.second,+ shouldStickToDarkTheme: true,+ isInAlert: true,+ ),+ ],+ title: "Remove these photos?",+ actionSheetType: ActionSheetType.defaultActionSheet,+ );+ if (actionResult?.action != null) {+ if (actionResult!.action == ButtonAction.first) {+ await ClusterFeedbackService.instance.removeFilesFromCluster(+ widget.selectedFiles.files.toList(),+ widget.clusterID!,+ );+ }+ Bus.instance.fire(PeopleChangedEvent());+ }+ widget.selectedFiles.clearAll();+ if (mounted) {+ setState(() => {});+ }+ }+Future<void> _copyLink() async {+ print("INSIDE COPY LINK");if (_cachedCollectionForSharedLink != null) {final String collectionKey = Base58Encode(CollectionsService.instance