summaryrefslogtreecommitdiff
path: root/src/Thumbnail.vala
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff.email>2023-06-28 21:35:52 +0200
committerJörg Frings-Fürst <debian@jff.email>2023-06-28 21:35:52 +0200
commitb86540b743f1a87a163ffb811c8fe22a01fefa38 (patch)
treeb47cb3bb83c2377234226fb3987ab3320a987dd9 /src/Thumbnail.vala
parentac6e0b731b9f0b2efd392e3309a5c07e2a66adad (diff)
parente905d8e16eec152d19797937f13ba3cf4b8f8aca (diff)
Merge branch 'release/debian/0.32.1-1'debian/0.32.1-1
Diffstat (limited to 'src/Thumbnail.vala')
-rw-r--r--src/Thumbnail.vala9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/Thumbnail.vala b/src/Thumbnail.vala
index f47fc69..51d2612 100644
--- a/src/Thumbnail.vala
+++ b/src/Thumbnail.vala
@@ -169,14 +169,15 @@ public class Thumbnail : MediaSourceItem {
}
public static int64 exposure_time_ascending_comparator(void *a, void *b) {
- int64 time_a = (int64) (((Thumbnail *) a)->media.get_exposure_time());
- int64 time_b = (int64) (((Thumbnail *) b)->media.get_exposure_time());
- int64 result = (time_a - time_b);
+ var time_a = (((Thumbnail *) a)->media.get_exposure_time());
+ var time_b = (((Thumbnail *) b)->media.get_exposure_time());
+
+ var result = nullsafe_date_time_comperator(time_a, time_b);
return (result != 0) ? result : filename_ascending_comparator(a, b);
}
- public static int64 exposure_time_desending_comparator(void *a, void *b) {
+ public static int64 exposure_time_descending_comparator(void *a, void *b) {
int64 result = exposure_time_ascending_comparator(b, a);
return (result != 0) ? result : filename_descending_comparator(a, b);