I ran into a problem with the implementation of the zoom software on the android. In a nutshell, I made an overlay with buttons on top of the map and when pressed, the zoom should change, but nothing happens. Here is the code snippet:
mapButtonZoomPlus.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { mZoom += 1; Log.d(TAG, "mapButtonZoomPlus click"); CameraPosition lCameraPosition = new CameraPosition(map.getMapWindow().getMap().getCameraPosition().getTarget(), mZoom, 0f, 0f); com.yandex.mapkit.Animation lAnimation = new com.yandex.mapkit.Animation(com.yandex.mapkit.Animation.Type.SMOOTH, 0.3f); map.getMapWindow().getMap().move(lCameraPosition, lAnimation, null); } });
getMapWindow () cleared, but the result is zero. At the same time, the zoom is fine tuned with your fingers. Tell me what could be the reason?