<fragment
android_layout_width="match_parent"
android_layout_height="match_parent" android_id="@+id/map" tools_context=".MapsActivity"
android_name="com.google.android.gms.maps.SupportMapFragment"
map_cameraTargetLat="40.689213"
map_cameraTargetLng="-74.044626"
map_cameraZoom="20"
map_uiZoomControls="true"
map_mapType="satellite"
map_cameraTilt="80"
map_cameraBearing="112.5"/>
![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjxrY3R8jW2zMEjD1y6AA8h7sfXv8ZWGmK3vr8OK8bx8XkAh4hx813sZ-GTgSR3PiOO0Z6UheS3XdQ-bCczJfxSCSjUVaWkrKBOVV6Sfd1XoidckPT0KY7tO3vwMlXGHyADqoErnWOjfS0/s640/initialize+map+in+xml+demo.png)
![](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgXk0_9XO8oR8iFzNbOsdCMSde7jUoKv6ZH93b3nUhdcxrqi8AXqYWru54xr_JzE-xaJ6is0pwfqF6xvAc63-R_AtHKfMsoYCe5ED7k-ePbN7vWm7mPi2c9j6ihAX9m3m4KpFILOkQF4m8/s640/initialize+map+in+xml.png)
This video show how to modify last example of "Add Marker to Google Map (Google Maps Android API v2)" to initialize map in layout xmp, layout/activity_maps.xml. In order to demonstrate on screen, I run BlueStacks App Player as Android Emulator.
Next: Detect touch on GoogleMap, onMapClick() and onMapLongClick()
~ Step-by-step of Android Google Maps Activity using Google Maps Android API v2, on Android Studio
0 comments:
Post a Comment