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

BaseMarkerOptions.java breaks NativeScript compatibility #4761

Closed

Description

@EddyVerbruggen

Hi folks,

Since Mapbox for Android 4.0.0 the annotation logic has been partially moved to a new BaseMarkerOptions superclass. This class has a title property as well as a title setter.

I understand why it was changed in the way it is, but it breaks using markers for the Mapbox NativeScript plugin as the NativeScript runtime can't distinguish the property from the setter.

Platform: Android (NativeScript)
Mapbox SDK version: 4.0.0

Steps to trigger behavior

Please check my description in the NativeScript issue tracker for a way to reproduce this in a NativeScript app.

Possible solution

We don't need the current setters like title(..) removed, but we'd be very much helped if regular Java setters like setTitle are added to BaseMarkerOptions.java. Until that's added I'm afraid we can't update the Android version of our plugin.

Activity

  1. added
    Android
    on Apr 20, 2016
  2. bleege commented on May 24, 2016

    @bleege
    Contributor

    @EddyVerbruggen I think this is doable as our primary concern is to be API compatible at the MarkerOptions level with the Google Maps API. We can create convenience wrapper methods for position, snippet, title, and icon called setPosition(), setSnippet(), setTitle(), and setIcon().

    Is there any other API breakages that you know of now or is BaseMarkerOptions the only one?

    /cc @rdlauer @tobrun @cammace @zugaldia

  3. EddyVerbruggen commented on May 25, 2016

    @EddyVerbruggen
    Author

    Hey @bleege thanks for taking note! AFAIK BaseMarkerOptions is the only problem for us.

  4. bleege commented on Jun 15, 2016

    @bleege
    Contributor

    @EddyVerbruggen I just created some wrappers for this and submitted PR #5367. Can you verify that this is what you'll need for the Cordova plugin? If so @zugaldia can work with you to get this into the next 4.1.0 build. Thanks!

  5. added this to the android-v4.1.0 milestone on Jun 15, 2016
  6. added a commit that references this issue on Jun 16, 2016
    cc1e261
  7. zugaldia commented on Jun 16, 2016

    @zugaldia
    Member

    @EddyVerbruggen we've now merged @bleege's PR into the release branch. You can expect a release candidate tomorrow or early next week that you can use to test the fix. Thanks again for your feedback.

  8. EddyVerbruggen commented on Jun 17, 2016

    @EddyVerbruggen
    Author

    Looks good guys, I'll check the RC shortly, thanks!

  9. zugaldia commented on Jun 21, 2016

    @zugaldia
    Member

    @EddyVerbruggen We released beta3 yesterday, feel free to give it a test #5415

  10. bleege commented on Jun 23, 2016

    @bleege
    Contributor

    Awesome! Thanks for making this happen @EddyVerbruggen @zugaldia! I'm excited about getting the Cordova and NativeScript plugins back up to the latest code! 🚀

  11. EddyVerbruggen commented on Jul 8, 2016

    @EddyVerbruggen
    Author

    @bleege @zugaldia I waited a bit for 4.1.0 and had a great time implementing some new features for the NativeScript plugin today. Your setters worked perfectly, thanks a LOT!

    The next thing I'll be adding is offline maps support, and then give the Cordova plugin some love.

  12. bleege commented on Jul 8, 2016

    @bleege
    Contributor

    @EddyVerbruggen That's great to hear! Thanks so much for your work keeping the NativeScript and Cordova plugins up to date! 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Android

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions