2015年5月20日 星期三

[Android] 隱藏百度地圖3.x SDK 縮放鍵

一個function就搞定


1
2
3
4
5
6
7
8
9
10
11
12
13
  //隐藏 缩放控件和  百度logo  
    private void hideZoomCtler()  
    {  
        if(mMapView==null)  
            return ;  
        int count = mMapView.getChildCount();  
        for (int i = 0; i < count; i++) {  
            View child = mMapView.getChildAt(i);  
            // 隐藏百度logo ZoomControl  
            if (child instanceof ImageView || child instanceof ZoomControls)  
                child.setVisibility(View.INVISIBLE);  
        }  
    }





參考文章
http://blog.csdn.net/weizongwei5/article/details/39178243

沒有留言:

張貼留言