Android 9 compatibility, fix #550
This commit is contained in:
parent
e6a90a8da5
commit
4ebca73023
@ -29,6 +29,7 @@
|
||||
- ViewController refactor [#523](https://github.com/mapsforge/vtm/pull/523)
|
||||
- `ViewController.setScreenSize` renamed to `setViewSize`
|
||||
- `ViewController.setMapScreenCenter` renamed to `setMapViewCenter`
|
||||
- Android 9 compatibility [#550](https://github.com/mapsforge/vtm/issues/550)
|
||||
- JTS (LocationTech) [#484](https://github.com/mapsforge/vtm/issues/484)
|
||||
- Many other minor improvements and bug fixes
|
||||
- [Solved issues](https://github.com/mapsforge/vtm/issues?q=is%3Aclosed+milestone%3A0.10.0)
|
||||
|
@ -15,6 +15,10 @@ implementation 'org.slf4j:slf4j-api:1.7.25'
|
||||
|
||||
### Android
|
||||
```groovy
|
||||
repositories {
|
||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||
}
|
||||
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]'
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-arm64-v8a'
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-armeabi'
|
||||
@ -23,11 +27,15 @@ implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-mips'
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-mips64'
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-x86'
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-x86_64'
|
||||
implementation 'com.caverock:androidsvg:1.2.2-beta-1'
|
||||
implementation 'com.caverock:androidsvg:1.3-SNAPSHOT'
|
||||
```
|
||||
|
||||
### Android (libGDX)
|
||||
```groovy
|
||||
repositories {
|
||||
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
|
||||
}
|
||||
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]'
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-arm64-v8a'
|
||||
implementation 'org.mapsforge:vtm-android:[CURRENT-VERSION]:natives-armeabi'
|
||||
@ -43,7 +51,7 @@ implementation 'org.mapsforge:vtm-android-gdx:[CURRENT-VERSION]:natives-x86'
|
||||
implementation 'org.mapsforge:vtm-android-gdx:[CURRENT-VERSION]:natives-x86_64'
|
||||
implementation 'com.badlogicgames.gdx:gdx:1.9.8'
|
||||
implementation 'com.badlogicgames.gdx:gdx-backend-android:1.9.8'
|
||||
implementation 'com.caverock:androidsvg:1.2.2-beta-1'
|
||||
implementation 'com.caverock:androidsvg:1.3-SNAPSHOT'
|
||||
```
|
||||
|
||||
### iOS
|
||||
|
@ -12,7 +12,8 @@
|
||||
<application
|
||||
android:allowBackup="true"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:label="@string/app_name">
|
||||
android:label="@string/app_name"
|
||||
android:usesCleartextTraffic="true">
|
||||
<activity
|
||||
android:name=".Samples"
|
||||
android:configChanges="keyboardHidden|orientation|screenSize">
|
||||
|
@ -3,7 +3,7 @@ apply plugin: 'com.github.dcendents.android-maven'
|
||||
|
||||
dependencies {
|
||||
api project(':vtm')
|
||||
api 'com.caverock:androidsvg:1.2.2-beta-1'
|
||||
api 'com.caverock:androidsvg:1.3-SNAPSHOT'
|
||||
}
|
||||
|
||||
android {
|
||||
|
@ -15,7 +15,8 @@
|
||||
android:name=".App"
|
||||
android:allowBackup="true"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:label="@string/application_name">
|
||||
android:label="@string/application_name"
|
||||
android:usesCleartextTraffic="true">
|
||||
|
||||
<!-- android:theme="@style/Theme.TileMap" -->
|
||||
<activity
|
||||
|
@ -100,12 +100,8 @@ class GwtMap extends GdxMap {
|
||||
ts = DefaultSources.STAMEN_TONER.build();
|
||||
else if ("osm".equals(mapName))
|
||||
ts = DefaultSources.OPENSTREETMAP.build();
|
||||
else if ("osm-transport".equals(mapName))
|
||||
ts = DefaultSources.OSM_TRANSPORT.build();
|
||||
else if ("watercolor".equals(mapName))
|
||||
ts = DefaultSources.STAMEN_WATERCOLOR.build();
|
||||
else if ("imagico".equals(mapName))
|
||||
ts = DefaultSources.IMAGICO_LANDCOVER.build();
|
||||
else if ("ne-landcover".equals(mapName))
|
||||
ts = DefaultSources.NE_LANDCOVER.build();
|
||||
else if ("hikebike".equals(mapName))
|
||||
|
@ -1,6 +1,7 @@
|
||||
/*
|
||||
* Copyright 2013 Hannes Janetzek
|
||||
* Copyright 2016 Andrey Novikov
|
||||
* Copyright 2016 devemux86
|
||||
* Copyright 2016-2018 devemux86
|
||||
*
|
||||
* This file is part of the OpenScienceMap project (http://www.opensciencemap.org).
|
||||
*
|
||||
@ -28,45 +29,36 @@ public class DefaultSources {
|
||||
|
||||
private static final FadeStep[] FADE_STEPS = new FadeStep[]{
|
||||
new FadeStep(0, 8 - 1, 1, 0.7f),
|
||||
// dont fade between zoom-min/max
|
||||
// don't fade between zoom-min/max
|
||||
// fade above zoom max + 2, interpolate 1 to 0
|
||||
new FadeStep(8 - 1, 8 + 1, 0.7f, 0)
|
||||
};
|
||||
|
||||
public static Builder<?> OPENSTREETMAP = BitmapTileSource.builder()
|
||||
.url("http://tile.openstreetmap.org")
|
||||
.zoomMax(18);
|
||||
|
||||
public static Builder<?> OSM_TRANSPORT = BitmapTileSource.builder()
|
||||
.url("http://a.tile.thunderforest.com/transport")
|
||||
.url("https://tile.openstreetmap.org")
|
||||
.zoomMax(18);
|
||||
|
||||
public static Builder<?> STAMEN_TONER = BitmapTileSource.builder()
|
||||
.url("http://a.tile.stamen.com/toner")
|
||||
.url("https://stamen-tiles.a.ssl.fastly.net/toner")
|
||||
.zoomMax(18);
|
||||
|
||||
public static Builder<?> STAMEN_WATERCOLOR = BitmapTileSource.builder()
|
||||
.url("http://a.tile.stamen.com/watercolor")
|
||||
.url("https://stamen-tiles.a.ssl.fastly.net/watercolor")
|
||||
.tilePath("/{Z}/{X}/{Y}.jpg")
|
||||
.zoomMax(18);
|
||||
|
||||
public static Builder<?> IMAGICO_LANDCOVER = BitmapTileSource.builder()
|
||||
.url("http://www.imagico.de/map/tiles/landcover")
|
||||
.tilePath("/{Z}/{X}/{Y}.jpg")
|
||||
.zoomMax(6);
|
||||
|
||||
public static Builder<?> NE_LANDCOVER = BitmapTileSource.builder()
|
||||
.url("http://opensciencemap.org/tiles/ne")
|
||||
.fadeSteps(FADE_STEPS)
|
||||
.zoomMax(8);
|
||||
|
||||
public static Builder<?> HIKEBIKE = BitmapTileSource.builder()
|
||||
.url("http://tiles.wmflabs.org/hikebike")
|
||||
.url("https://tiles.wmflabs.org/hikebike")
|
||||
.tilePath("/{Z}/{X}/{Y}.png")
|
||||
.zoomMax(17);
|
||||
|
||||
public static Builder<?> HIKEBIKE_HILLSHADE = BitmapTileSource.builder()
|
||||
.url("http://tiles.wmflabs.org/hillshading")
|
||||
.url("https://tiles.wmflabs.org/hillshading")
|
||||
.tilePath("/{Z}/{X}/{Y}.png")
|
||||
.zoomMax(14);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user