Location refactor compiles and seemingly works
Location updates now handled in a more compose friendly way via StateFlow Lots of small changed in MainActivity and DetailDialogShell to make them platform independent Add new platform apis for openUrl, openMap (AppNavigator) Add Platform independent OutboxScheduler Try to clean up event handling of FoundEvents and location updates (need more cleanup) New wrapper for handling App Context in shared (could be used to clean up integration further)
This commit is contained in:
@@ -42,7 +42,7 @@ data class LocationUpdates(
|
||||
/** Simple, common store (replaces various platform stores). */
|
||||
object LastLocationStore {
|
||||
private val _lastKnown = MutableStateFlow<GeoPoint?>(null)
|
||||
val lastKnown: StateFlow<GeoPoint?> = _lastKnown.asStateFlow()
|
||||
val lastKnownLocation: StateFlow<GeoPoint?> = _lastKnown.asStateFlow()
|
||||
|
||||
fun update(p: GeoPoint?) { _lastKnown.value = p }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user