Loading play-services-maps-core-mapbox/src/main/kotlin/org/microg/gms/maps/mapbox/GoogleMap.kt +3 −3 Original line number Diff line number Diff line Loading @@ -65,8 +65,8 @@ import org.microg.gms.maps.mapbox.utils.toMapbox private fun <T : Any> LongSparseArray<T>.values() = (0 until size()).mapNotNull { valueAt(it) } fun runOnMainLooper(method: () -> Unit) { if (Looper.myLooper() == Looper.getMainLooper()) { fun runOnMainLooper(forceQueue: Boolean = false, method: () -> Unit) { if (!forceQueue && Looper.myLooper() == Looper.getMainLooper()) { method() } else { Handler(Looper.getMainLooper()).post { Loading Loading @@ -833,7 +833,7 @@ class GoogleMapImpl(context: Context, var options: GoogleMapOptions) : AbstractG * null), otherwise that results in other problems (e.g. Gas Now app not * initializing). */ mapView?.post { runOnMainLooper(forceQueue = true) { Log.d(TAG, "Invoking callback now: map cannot be initialized because it is not shown (yet)") runCallback() } Loading Loading
play-services-maps-core-mapbox/src/main/kotlin/org/microg/gms/maps/mapbox/GoogleMap.kt +3 −3 Original line number Diff line number Diff line Loading @@ -65,8 +65,8 @@ import org.microg.gms.maps.mapbox.utils.toMapbox private fun <T : Any> LongSparseArray<T>.values() = (0 until size()).mapNotNull { valueAt(it) } fun runOnMainLooper(method: () -> Unit) { if (Looper.myLooper() == Looper.getMainLooper()) { fun runOnMainLooper(forceQueue: Boolean = false, method: () -> Unit) { if (!forceQueue && Looper.myLooper() == Looper.getMainLooper()) { method() } else { Handler(Looper.getMainLooper()).post { Loading Loading @@ -833,7 +833,7 @@ class GoogleMapImpl(context: Context, var options: GoogleMapOptions) : AbstractG * null), otherwise that results in other problems (e.g. Gas Now app not * initializing). */ mapView?.post { runOnMainLooper(forceQueue = true) { Log.d(TAG, "Invoking callback now: map cannot be initialized because it is not shown (yet)") runCallback() } Loading