use of net.osmand.plus.views.layers.base.BaseMapLayer in project Osmand by osmandapp.
the class DownloadTilesFragment method shouldShowDialog.
public static boolean shouldShowDialog(@NonNull OsmandApplication app) {
BaseMapLayer mainLayer = app.getOsmandMap().getMapView().getMainLayer();
MapTileLayer mapTileLayer = mainLayer instanceof MapTileLayer ? ((MapTileLayer) mainLayer) : null;
ITileSource tileSource = app.getSettings().getMapTileSource(false);
return mapTileLayer != null && mapTileLayer.isVisible() && tileSource.couldBeDownloadedFromInternet();
}
Aggregations