example: use stored map position

This commit is contained in:
Hannes Janetzek
2014-03-24 05:12:49 +01:00
parent ce38b484f6
commit 41c92f0a38
5 changed files with 11 additions and 8 deletions

View File

@@ -18,6 +18,7 @@
import org.oscim.layers.tile.vector.BuildingLayer;
import org.oscim.layers.tile.vector.labeling.LabelLayer;
import org.oscim.map.Layers;
import org.oscim.map.Map;
import org.oscim.theme.VtmThemes;
import android.os.Bundle;
@@ -27,19 +28,17 @@ public class SimpleMapActivity extends BaseMapActivity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Map m = this.map();
Layers layers = mMap.layers();
layers.add(new BuildingLayer(mMap, mBaseLayer));
layers.add(new LabelLayer(mMap, mBaseLayer));
//layers.add(new TileGridLayer(mMap));
mMap.setTheme(VtmThemes.DEFAULT);
m.setTheme(VtmThemes.DEFAULT);
//mMap.setTheme(VtmThemes.TRONRENDER);
//mMap.setTheme(VtmThemes.TRON2);
//mMap.setTheme(VtmThemes.OSMARENDER);
mMap.setMapPosition(53.08, 8.83, Math.pow(2, 10));
}
// Stress testing