由网友(ゝ心 伤)分享简介:每当我移动地图,标记也正与但我想通过保持标记在地图的中心,不断向移动地图。 Whenever I move the map,Marker is also moving with that But I want to move the map by keeping the marker at the center of...
每当我移动地图,标记也正与但我想通过保持标记在地图的中心,不断向移动地图。
Whenever I move the map,Marker is also moving with that But I want to move the map by keeping the marker at the center of Map as constant.
我怎样才能达致这?
推荐答案
你为什么不添加标记作为视图。它覆盖在地图上的顶部。
Why don't you add your marker as a view. overlay it on top of the map.
<RelaiveLayout android:layout_width="wrap_content" android:layout_height="wrap_content" >
<mapView ... />
<ImageView android:center_in_parent="true" ... android:src="@drawable/urmarker" />
</RelativeLayout>
如果您使用的是MapFragment标记添加到片段活动
or if your using a MapFragment add the marker to the fragment activity
相关推荐
最新文章