Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

docs: Add sharee pin feature to internal changes

Prateek Sunal322adcf4a591
diff --git a/mobile/apps/photos/lib/services/collections_service.dart b/mobile/apps/photos/lib/services/collections_service.dart
index 889d8f2901..9dc4c28ea4 100644
--- a/mobile/apps/photos/lib/services/collections_service.dart
+++ b/mobile/apps/photos/lib/services/collections_service.dart
@@ -456,6 +456,12 @@ class CollectionsService {
// Sort incoming collections, then separate pinned from rest
incoming.sort(
(first, second) {
+ // Sharee-pinned collections should come first
+ final firstPinned = first.hasShareePinned();
+ final secondPinned = second.hasShareePinned();
+ if (firstPinned && !secondPinned) return -1;
+ if (!firstPinned && secondPinned) return 1;
+
int comparison;
if (sortKey == AlbumSortKey.albumName) {
comparison = compareAsciiLowerCaseNatural(
@@ -477,18 +483,6 @@ class CollectionsService {
},
);
- // Separate sharee-pinned collections to show them first
- final List<Collection> pinnedIncoming = [];
- final List<Collection> restIncoming = [];
- for (final collection in incoming) {
- if (collection.hasShareePinned()) {
- pinnedIncoming.add(collection);
- } else {
- restIncoming.add(collection);
- }
- }
- final sortedIncoming = pinnedIncoming + restIncoming;
-
outgoing.sort(
(first, second) {
int comparison;
@@ -512,7 +506,7 @@ class CollectionsService {
},
);
- return SharedCollections(outgoing, sortedIncoming, quickLinks);
+ return SharedCollections(outgoing, incoming, quickLinks);
}
Future<List<Collection>> getCollectionForOnEnteSection() async {
diff --git a/mobile/apps/photos/scripts/internal_changes.txt b/mobile/apps/photos/scripts/internal_changes.txt
index b4e7bf7eb3..26810e37d0 100644
--- a/mobile/apps/photos/scripts/internal_changes.txt
+++ b/mobile/apps/photos/scripts/internal_changes.txt
@@ -1,3 +1,4 @@
+- Prateek: (i) Pin/Unpin for "Shared with you" albums (mobile + web)
- Prateek: Change behaviour of bottom action sheet for iOS (test every sheet)
- Laurens: (i) Manual people tagging
- Prateek: (i) Video streaming bitrate changes & enable streaming by default