开发者

How to change the position of the Map controller in MapView in android?

开发者 https://www.devze.com 2023-04-09 04:29 出处:网络
How to change the position of the Map controller (zoo开发者_JS百科n in/out) in MapView in android other than the default position in the bottom ?zoomView = (LinearLayout) mapView.getZoomControls();

How to change the position of the Map controller (zoo开发者_JS百科n in/out) in MapView in android other than the default position in the bottom ?


zoomView = (LinearLayout) mapView.getZoomControls();

zoomView.setLayoutParams(new ViewGroup.LayoutParams
  (ViewGroup.LayoutParams.WRAP_CONTENT,
   ViewGroup.LayoutParams.WRAP_CONTENT)); 

zoomView.setGravity(Gravity.BOTTOM | Gravity.CENTER_HORIZONTAL);
mapView.addView(zoomView);
0

精彩评论

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