mirror of
https://github.com/rt-bishop/Look4Sat.git
synced 2026-10-02 03:15:37 +00:00
Added multiple fixes to RadarScreen and components
This commit is contained in:
1 parent
cdf642d9f3
commit
5b62474c27
16 files changed
+304
-184
No files matched your search
@@ -1,9 +1,11 @@
|
||||
package com.rtbishop.look4sat.domain.repository
|
||||
|
||||
import com.rtbishop.look4sat.domain.predict.GeoPos
|
||||
import kotlinx.coroutines.flow.StateFlow
|
||||
|
||||
interface ISensorsRepo {
|
||||
val orientation: StateFlow<Pair<Float, Float>>
|
||||
fun getMagDeclination(geoPos: GeoPos, time: Long = System.currentTimeMillis()): Float
|
||||
fun enableSensor()
|
||||
fun disableSensor()
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
package com.rtbishop.look4sat.domain.usecase
|
||||
|
||||
interface IAddToCalendar {
|
||||
operator fun invoke(name: String, aosTime: Long, losTime: Long)
|
||||
}
|
||||
@@ -17,6 +17,7 @@
|
||||
*/
|
||||
package com.rtbishop.look4sat.domain.utility
|
||||
|
||||
import java.util.Locale
|
||||
import java.util.concurrent.TimeUnit
|
||||
|
||||
fun Long.toTimerString(): String {
|
||||
@@ -24,7 +25,7 @@ fun Long.toTimerString(): String {
|
||||
val hours = TimeUnit.MILLISECONDS.toHours(this)
|
||||
val minutes = TimeUnit.MILLISECONDS.toMinutes(this) % 60
|
||||
val seconds = TimeUnit.MILLISECONDS.toSeconds(this) % 60
|
||||
return String.format(format, hours, minutes, seconds)
|
||||
return String.format(Locale.ENGLISH, format, hours, minutes, seconds)
|
||||
}
|
||||
|
||||
fun Float.round(decimals: Int): Float {
|
||||
|
||||
Reference in new issue
Block a user