Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Android AnimatedMarkerActivity bugs in test app #7380

Closed
klblk opened this issue Dec 12, 2016 · 3 comments
Closed

Android AnimatedMarkerActivity bugs in test app #7380

klblk opened this issue Dec 12, 2016 · 3 comments
Labels
Android Mapbox Maps SDK for Android

Comments

@klblk
Copy link

klblk commented Dec 12, 2016

Platform: Android
Mapbox SDK version: 4.2.0-beta5

Steps to trigger behavior

  1. https://github.com/mapbox/mapbox-gl-native/blob/master/platform/android/MapboxGLAndroidSDKTestApp/src/main/java/com/mapbox/mapboxsdk/testapp/activity/annotation/AnimatedMarkerActivity.java

a) getLatLngInBounds() returns an incorrect result. Problem in mapboxMap.getProjection().getVisibleRegion().latLngBounds value:

bounds N:85.02070418030257; E:134.99996915347242; S:-85.02070418030256; W:-134.99996915347265

b) Animated markers blinking if the camera shift (sorry, I'm bad gif-maker):
myimage

c) #6422 actual (if change MarkerViewOptions to MarkerOptions passengerMarker)

@tobrun
Copy link
Member

tobrun commented Dec 12, 2016

@klblk could you try testing with the latest SNAPSHOT? We made some changes since the last beta, I'm trying to pinpoint if the root cause will be different from #6762.

dependencies {
    compile ('com.mapbox.mapboxsdk:mapbox-android-sdk:4.2.0-SNAPSHOT@aar') {
        transitive=true
    }
}

To reach the dependency you need to add following repository to the root directory gradle file:

    maven { url "http://oss.sonatype.org/content/repositories/snapshots/" }

@klblk
Copy link
Author

klblk commented Dec 12, 2016

Yes, all reproduce with latest SNAPSHOT.
"a", "b" problems not reproduce with beta-4.
Android 5.1 (Nexus 4)

@tobrun tobrun added the Android Mapbox Maps SDK for Android label Dec 12, 2016
@tobrun
Copy link
Member

tobrun commented Dec 13, 2016

a) The issue that LatLngBounds returns a wrong bounding box is noted in #6769, this is because we changed the way the OnMapReadyCallback is invoked and at that time the View isn't measured yet. To workaround this I would advice you to wrap it in a runnable or use addOnGlobalLayoutListener. We are working on including this as a requirement to invoke the OnMapReady but this will only land as part of the 5.0.0 release since it requires some internal refactoring.

b) The issue in #6762 will be the same as shown here. Going to use that issue to investigate.

Since both issues are tracked elsewhere, going to close as duplicate.

Thanks again for reaching out and reporting your issue!

@tobrun tobrun closed this as completed Dec 13, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Android Mapbox Maps SDK for Android
Projects
None yet
Development

No branches or pull requests

2 participants