diff --git a/OsmAnd/src/net/osmand/plus/OsmandSettings.java b/OsmAnd/src/net/osmand/plus/OsmandSettings.java index 25199c5869..85e5e5751d 100644 --- a/OsmAnd/src/net/osmand/plus/OsmandSettings.java +++ b/OsmAnd/src/net/osmand/plus/OsmandSettings.java @@ -651,7 +651,7 @@ public class OsmandSettings { public float getSettingsZoomScale(float density){ // by default scale between [0, 1[ density (because of lots map complains) - return MAP_ZOOM_SCALE_BY_DENSITY.get() + (float)Math.min(Math.sqrt(Math.max(0, density - 1)), 1); + return MAP_ZOOM_SCALE_BY_DENSITY.get() + (float)Math.sqrt(Math.max(0, density - 1)); } @@ -993,7 +993,10 @@ public class OsmandSettings { public static final String EXTERNAL_STORAGE_DIR = "external_storage_dir"; //$NON-NLS-1$ public File getExternalStorageDirectory() { - String defaultLocation = getDefaultExternalStorageLocation(); + String defaultLocation = ctx.getExternalServiceAPI().getExternalStorageDirectory(); + if(Build.VERSION.SDK_INT >= VERSION_DEFAULTLOCATION_CHANGED && !new File(defaultLocation, IndexConstants.APP_DIR).exists()) { + defaultLocation += "/Android/data/" + ctx.getPackageName(); + } return new File(settingsAPI.getString(globalPreferences, EXTERNAL_STORAGE_DIR, defaultLocation)); } diff --git a/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java b/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java index 5ba6ebedea..b1d7a00c04 100644 --- a/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java +++ b/OsmAnd/src/net/osmand/plus/activities/SettingsActivity.java @@ -4,30 +4,27 @@ package net.osmand.plus.activities; import java.io.File; import java.util.Date; -import android.content.SharedPreferences; -import android.widget.ScrollView; import net.osmand.IndexConstants; import net.osmand.plus.OsmandApplication; import net.osmand.plus.OsmandPlugin; import net.osmand.plus.R; import net.osmand.plus.Version; -import net.osmand.plus.rastermaps.SettingsRasterMapsActivity; -import net.osmand.util.Algorithms; import android.app.AlertDialog; import android.app.AlertDialog.Builder; import android.content.Intent; +import android.content.SharedPreferences; import android.content.pm.ApplicationInfo; import android.content.pm.PackageManager; import android.os.Bundle; import android.preference.Preference; import android.preference.PreferenceScreen; -import android.preference.Preference.OnPreferenceClickListener; import android.text.SpannableString; import android.text.format.DateFormat; import android.text.method.LinkMovementMethod; import android.text.style.ClickableSpan; import android.util.TypedValue; import android.view.View; +import android.widget.ScrollView; import android.widget.TextView; public class SettingsActivity extends SettingsBaseActivity { diff --git a/OsmAnd/src/net/osmand/plus/views/MapControlsLayer.java b/OsmAnd/src/net/osmand/plus/views/MapControlsLayer.java index 24b91505ef..37bcd63de7 100644 --- a/OsmAnd/src/net/osmand/plus/views/MapControlsLayer.java +++ b/OsmAnd/src/net/osmand/plus/views/MapControlsLayer.java @@ -393,7 +393,7 @@ public class MapControlsLayer extends OsmandMapLayer { final AlertDialog.Builder bld = new AlertDialog.Builder(view.getContext()); float scale = view.getZoomScale(); int p = (int) ((scale > 0 ? 1 : -1) * Math.round(scale * scale * 100)) + 100; - final TIntArrayList tlist = new TIntArrayList(new int[] { 75, 100, 150, 200, 300, 400 }); + final TIntArrayList tlist = new TIntArrayList(new int[] { 75, 100, 150, 200, 300, 400, 500 }); final List values = new ArrayList(); int i = -1; for (int k = 0; k <= tlist.size(); k++) {