Mapbox: Track info window shown

This commit is contained in:
Marvin W 2020-09-15 16:43:54 +02:00
parent c965e3cd0b
commit e70e6bc956
No known key found for this signature in database
GPG Key ID: 072E9235DB996F2A

View File

@ -16,6 +16,7 @@
package org.microg.gms.maps.mapbox.model
import android.os.Parcel
import android.util.Log
import com.google.android.gms.dynamic.IObjectWrapper
import com.google.android.gms.dynamic.ObjectWrapper
@ -42,6 +43,8 @@ class MarkerImpl(private val map: GoogleMapImpl, private val id: String, options
private var draggable: Boolean = options.isDraggable
private var tag: IObjectWrapper? = null
private var infoWindowShown = false
override var annotation: Symbol? = null
override var removed: Boolean = false
override val annotationOptions: SymbolOptions
@ -108,15 +111,17 @@ class MarkerImpl(private val map: GoogleMapImpl, private val id: String, options
override fun showInfoWindow() {
Log.d(TAG, "unimplemented Method: showInfoWindow")
infoWindowShown = true
}
override fun hideInfoWindow() {
Log.d(TAG, "unimplemented Method: hideInfoWindow")
infoWindowShown = false
}
override fun isInfoWindowShown(): Boolean {
Log.d(TAG, "unimplemented Method: isInfoWindowShow")
return false
return infoWindowShown
}
override fun setVisible(visible: Boolean) {
@ -202,6 +207,13 @@ class MarkerImpl(private val map: GoogleMapImpl, private val id: String, options
override fun getTag(): IObjectWrapper = tag ?: ObjectWrapper.wrap(null)
override fun onTransact(code: Int, data: Parcel, reply: Parcel?, flags: Int): Boolean =
if (super.onTransact(code, data, reply, flags)) {
true
} else {
Log.d(TAG, "onTransact [unknown]: $code, $data, $flags"); false
}
companion object {
private val TAG = "GmsMapMarker"
}