Fixes preview of Android Acticity in the Studio XML editor

This commit is contained in:
Leith Bade
2015-08-18 17:21:08 +10:00
parent a093182c27
commit ac86ce39ad

View File

@@ -742,7 +742,9 @@ public class MapView extends FrameLayout implements LocationListener {
}
public void onSizeChanged(int width, int height, int oldw, int oldh) {
mNativeMapView.resizeView((int) (width / mScreenDensity), (int) (height / mScreenDensity));
if (!isInEditMode()) {
mNativeMapView.resizeView((int) (width / mScreenDensity), (int) (height / mScreenDensity));
}
}
// This class handles SurfaceHolder callbacks