Android First Look - Map View

Learn to code, Android without APIs is not more than virtual machine... Therefore always in eclipse choose Google API (atop of Android 1.5 now).
Snippets:

- for code itself:
...

import com.google.android.maps.MapActivity;
...

@Override
protected boolean isRouteDisplayed() {
// TODO Auto-generated method stub
return false;
}

- for manifest:

<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION">
</uses-permission>
<uses-permission android:name="android.permission.INTERNET">
</uses-permission>

- for layout:
<com.google.android.maps.MapView
android:id="@+id/mapview1"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:enabled="true"
android:clickable="true"
android:apiKey="..." >

Comments

Popular Posts