开发者

Can i put a googlemap in the middle section of my user interface?

开发者 https://www.devze.com 2023-01-25 06:58 出处:网络
i need that my user interfa开发者_如何转开发ce haves 3 sections NORTH SECTION: four textviews with info about a user

i need that my user interfa开发者_如何转开发ce haves 3 sections

NORTH SECTION: four textviews with info about a user

MIDDLE SECTION: a googlemap view with the position of the user

SOUTH SECTION: a textview with time of last position, and a button to actualice the position (retrieving it from a database)

is this possible? i can't find any information about that on google or android developers guide...


You can use a relative layout having three children layouts. In the second layout add mapview.This will require to add google map apikey in its properties.

<LinearLayout>
      com.google.android.maps.MapView 
            android:id="@+id/mapview" 
            android:clickable="true" 
            android:focusable="true" 
            android:focusableInTouchMode="true" 
            android:layout_height="380px" 
            android:layout_width="540px" 
            android:layout_gravity="left|top" 
            android:apiKey="your key"/>
</LinearLayout>
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号