android - get a MapView from SupportMapFragment -


i have activity_main xml layout looks like:

<?xml version="1.0" encoding="utf-8"?>  <fragment xmlns:android="http://schemas.android.com/apk/res/android"     xmlns:map="http://schemas.android.com/apk/res-auto"     android:id="@+id/map"     android:layout_width="fill_parent"     android:layout_height="fill_parent"     class="com.google.android.gms.maps.supportmapfragment" /> 

can in mainactivity mapview xml layout?

you can this

googlemap mmap = ((supportmapfragment) getfragmentmanager()                 .findfragmentbyid(r.id.map)).getmap(); 

Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -