Commit Graph

8 Commits

Author SHA1 Message Date
AntsyLich b2015d1ef3 Migrate to Metro DI (#3608)
Assisted-by: Claude:claude-opus-5
2026-08-16 18:47:48 +00:00
MajorTanya 6d69903a56 Replace java.time APIs with kotlin(x).(date)time (#3001)
* Replace java.time APIs with kotlin(x).(date)time

kotlinx-datetime explicitly says in its README that it does not cover
i18n, so we have to stick with using their toJavaX converters wherever
we localise dates and times.

Yes, some of these replacements are... questionable. But I wanted to
try and maximise the replacement for now.

* Bump kotlinx-datetime to 0.8.0

* More kotlin.time/kotlinx-datetime replacements

* Remove redundant init block & make attributes val

* Replace new use of java.time.Instant
2026-08-02 16:58:25 +06:00
AntsyLich 87665736a9 Replace preference getter functions with properties (#3091) 2026-03-20 14:57:01 +06:00
MajorTanya 7a1c8a1b61 Fix pre-1970 upload date display in chapter list (#2779)
A user in #2777 was using the ComicInfo.xml Year/Month/Day fields to
indicate date of publication for some American comics, which often
predate the UNIX Epoch of 1970.

They were seeing "N/A" displays because this line of code discarded
date information for any time before Jan 1st, 1970.

The `toRelativeString` extension function used in the other
`relativeDateText` function already accounts for very distant dates
(anything >7 days away turns into full date, not relative, regardless
of setting, though disabling the relative timestamp setting
circumvents this with the same result). Removing this line should not
cause any issues as it is purely a display difference and the use case
of backdating comics to pre-1970 is worth it in my opinion.
2025-12-18 11:26:35 +00:00
AntsyLich e183cbb231 Revert a mishap in 7ff95e21ba 2024-02-17 03:28:48 +06:00
Maddie Witman 7ff95e21ba Refactor use of Java.util.date to Java.time.*, to fix localized date issues. (#402)
* Add support for localdate based relative times

* Update History Screen to use new localdate based relative times

* Update Updates Screen to use new localdate based relative times

* Cleaned up date util classes

* Updated build time display

* Code cleanup

* Fixed crash in settings

* Updated Preferences item

* Worker Info works

* Fixed Tracker date display

* Code changes to pass detekt
2024-02-16 17:09:00 +06:00
arkon 54f4711f7b Show next expected update in interval dialog
Related: #9793
2023-12-30 19:15:52 -05:00
arkon 3d0d5c0472 Misc refactoring
- Abstract away relative date string building
- Dedupe large update warning logic
2023-12-30 18:33:35 -05:00