本文整理汇总了Java中com.baidu.mapapi.map.MapView.removeViewAt方法的典型用法代码示例。如果您正苦于以下问题:Java MapView.removeViewAt方法的具体用法?Java MapView.removeViewAt怎么用?Java MapView.removeViewAt使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.baidu.mapapi.map.MapView
的用法示例。
在下文中一共展示了MapView.removeViewAt方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: IniView
import com.baidu.mapapi.map.MapView; //导入方法依赖的package包/类
@Override
protected void IniView() {
bt_Ok = (Button) findViewById(R.id.bt_Ok);
tv_location = (TextView) findViewById(R.id.tv_location);
mDrawerLayout = (DrawerLayout) findViewById(R.id.dl_left);
mTopbanner = (TopBanner) findViewById(R.id.topbanner);
mAboutAuthor = (TextView) findViewById(R.id.tv_about_me);
mCurrentLocation = (ImageView)findViewById(R.id.iv_location);
mStopMock = (ImageView)findViewById(R.id.iv_stop_location);
mPreciseLocation = (TextView)findViewById(R.id.tv_precise);
mAddProcess = (TextView) findViewById(R.id.tv_add_app);
//加载旋转动画
mOperatingAnim = AnimationUtils.loadAnimation(this, R.anim.spinloaing);
LinearInterpolator lin = new LinearInterpolator();
mOperatingAnim.setInterpolator(lin);
// 地图初始化
mMapView = (MapView) findViewById(R.id.bmapView);
mBaiduMap = mMapView.getMap();
// 开启定位图层
mBaiduMap.setMyLocationEnabled(true);
//隐藏地图比例尺
mMapView.showScaleControl(false);
//关闭缩放放大控件
mMapView.showZoomControls(false);
mMapView.removeViewAt(1);
// 定位初始化
mLocClient = new LocationClient(this);
}
示例2: initMap
import com.baidu.mapapi.map.MapView; //导入方法依赖的package包/类
/**
* init mapview
*/
public void initMap() {
mMapView = (MapView) findViewById(R.id.bmapView);
mBaiduMap = mMapView.getMap();
// remove map logo
mMapView.removeViewAt(1);
int childCount = mMapView.getChildCount();
View zoom = null;
for (int i = 0; i < childCount; i++) {
View child = mMapView.getChildAt(i);
if (child instanceof ZoomControls) {
zoom = child;
break;
}
}
zoom.setVisibility(View.GONE);
mBaiduMap = mMapView.getMap();
UiSettings mUiSettings = mBaiduMap.getUiSettings();
mUiSettings.setCompassEnabled(false);
mBaiduMap.setMyLocationEnabled(true);
mLocClient = new LocationClient(this);
mLocClient.registerLocationListener(myListener);
LocationClientOption option = new LocationClientOption();
option.setLocationMode(LocationClientOption.LocationMode.Hight_Accuracy);
option.setOpenGps(true);
option.setCoorType("bd09ll");
option.setScanSpan(1000);
option.setIsNeedAddress(true);
mLocClient.setLocOption(option);
mLocClient.start();
}