Reputation: 211
I want to display Map in one of my Fragment
I am using 4 fragments in which one shows the map but i don't want to use LocalActivityManager
to host a Activity inside a fragment. It is a deprecated class, but it offers the simplest solution.
By using MapActivity
it is starting a new Activity
which i don't want i want to display it in viewpager
and MapView
dont work in Fragment
.
Please suggest me how to get it.
Thanks for Help.
Upvotes: 0
Views: 335
Reputation: 211
I found no other way then the one mentioned in the following way...
https://stackoverflow.com/a/8126287
Upvotes: 0
Reputation: 1007339
Since Maps V1 (MapActivity
and kin) is deprecated, you could consider moving to the new Maps V2, which has MapFragment
(for native API Level 11 fragments) and SupportMapFragment
(for the Android Support Library's backport of fragments).
Upvotes: 1