mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-04-20 22:23:37 +00:00
Alias strings R to Res (#3619)
This commit is contained in:
parent
a687328f08
commit
0833a6767e
153 changed files with 1403 additions and 1350 deletions
|
|
@ -28,6 +28,7 @@ import org.meshtastic.proto.channel
|
|||
import org.meshtastic.proto.channelSettings
|
||||
import java.text.DateFormat
|
||||
import kotlin.time.Duration.Companion.days
|
||||
import org.meshtastic.core.strings.R as Res
|
||||
|
||||
private const val SECONDS_TO_MILLIS = 1000L
|
||||
|
||||
|
|
@ -38,7 +39,7 @@ fun MeshProtos.Position.formatPositionTime(dateFormat: DateFormat): String {
|
|||
val isOlderThanSixMonths = time * SECONDS_TO_MILLIS < sixMonthsAgo
|
||||
val timeText =
|
||||
if (isOlderThanSixMonths) {
|
||||
stringResource(org.meshtastic.core.strings.R.string.unknown_age)
|
||||
stringResource(Res.string.unknown_age)
|
||||
} else {
|
||||
dateFormat.format(time * SECONDS_TO_MILLIS)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue