Last Updated: February 25, 2016
·
1.455K
· coreform

MapFragment

There's a couple solutions for using MapView/MapActivity with Fragments, one is to use a forked version of the android-v4-support library (which makes every single FragmentActivity extend MapActivity) -or- BETTER to use a LocalActivityManager trick. I've written a little library that provides a few variants on the LocalActivityManager trick (for simple Fragment+Maps usage as well as Tabs+Fragment+Maps usage) and shows how to deal with some surrounding problems:

https://github.com/coreform/android-tandemactivities

This library is largely based off the R&D done by inazaruk as well as some other contributors to the topic on stackoverflow and myself.