有人可以告诉我如何向 Google Map Android API V2 添加自定义 Controller (如按钮)吗?我搜索了很多,看了看https://developers.google.com/maps/documentation/android/intro ,但我在这方面找不到任何东西。我之前在网络上使用 Javascript 做过同样的事情,比如向 map 添加 DIV。对于 Android,我找不到任何东西。
最佳答案
看这个 xml 会将您的 Layout
放在您将在 RelativeLayout
中使用的任何 View
的底部
<RelativeLayout
android:id="@+id/footer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:background="#FC0"
android:gravity="center" >
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="5dp"
android:text="Fixed Footer"
android:textColor="#000"
android:textSize="20sp" />
</RelativeLayout>
关于android - 如何向 Google Map Android API v2 添加自定义 Controller (如按钮)?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21717567/