From 2a4ea117b58cb085827ce0f8f12d3ba02802ad29 Mon Sep 17 00:00:00 2001 From: Neeraj Gupta <254676+ua741@users.noreply.github.com> Date: Tue, 17 May 2022 02:10:07 +0530 Subject: [PATCH] remove sort option: Oldest --- lib/ui/collections_gallery_widget.dart | 6 ------ lib/utils/local_settings.dart | 1 - 2 files changed, 7 deletions(-) diff --git a/lib/ui/collections_gallery_widget.dart b/lib/ui/collections_gallery_widget.dart index 48b9dcdda..59350abb7 100644 --- a/lib/ui/collections_gallery_widget.dart +++ b/lib/ui/collections_gallery_widget.dart @@ -120,9 +120,6 @@ class _CollectionsGalleryWidgetState extends State } else if (sortKey == AlbumSortKey.newestPhoto) { return second.thumbnail.creationTime .compareTo(first.thumbnail.creationTime); - } else if (sortKey == AlbumSortKey.oldestPhoto) { - return first.thumbnail.creationTime - .compareTo(second.thumbnail.creationTime); } else { return second.collection.updationTime .compareTo(first.collection.updationTime); @@ -407,9 +404,6 @@ class _CollectionsGalleryWidgetState extends State case AlbumSortKey.newestPhoto: text = "Newest"; break; - case AlbumSortKey.oldestPhoto: - text = "Oldest"; - break; case AlbumSortKey.lastUpdated: text = "Last updated"; } diff --git a/lib/utils/local_settings.dart b/lib/utils/local_settings.dart index e292c59a4..267d6413a 100644 --- a/lib/utils/local_settings.dart +++ b/lib/utils/local_settings.dart @@ -3,7 +3,6 @@ import 'package:shared_preferences/shared_preferences.dart'; enum AlbumSortKey { albumName, newestPhoto, - oldestPhoto, lastUpdated, }