[html]
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > <com.google.android.maps.MapView android:id="@+id/mapview" android:layout_width="fill_parent" android:layout_height="fill_parent" android:apiKey="008uu0x2a7GWlK2LzCW872afBAPLhJ-U2R26Wgw" /> </LinearLayout> 下面是核心代码,重要的地方我做了注释: