TradeMe / MapMe

The Android maps adapter
MIT License
841 stars 75 forks source link

androidX support #24

Closed dellisd closed 6 years ago

dellisd commented 6 years ago

Since MapMeAdapter inherits ListUpdateCallback from the legacy support library, the adapter cannot be used with androidX's DiffUtil.DiffResult.dispatchUpdatesTo().

josh-burton commented 6 years ago

Does using Jetifier not rewrite the old package name to the new one?

I was under the impression Jetifier would work for most libraries, except if the library used an annotation processor.

dellisd commented 6 years ago

Apparently not.

I'm still getting this error: e: Supertypes of the following classes cannot be resolved. Please make sure you have the required dependencies in the classpath: class nz.co.trademe.mapme.MapMeAdapter, unresolved supertypes: androidx.recyclerview.widget.ListUpdateCallback

josh-burton commented 6 years ago

I've also been able to reproduce this.

Rather than fixing this in MapMe I've filed a bug on the Android bug tracker, as this is the exact purpose of Jetifier: https://issuetracker.google.com/issues/112274081

Once AndroidX is stable we will migrate MapMe to use it, but until then Jetifier should be the solution to using it in a project that uses AndroidX.

josh-burton commented 6 years ago

This has now been fixed in AGP 3.2 RC01 💯