Skip to content

Commit 858ae5c

Browse files
committed
Update samples
1 parent cf13889 commit 858ae5c

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

vtm-playground/src/org/oscim/test/MapsforgeTest.java

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
*/
1818
package org.oscim.test;
1919

20+
import com.badlogic.gdx.Input;
2021
import org.mapsforge.map.awt.graphics.AwtGraphicFactory;
2122
import org.mapsforge.map.layer.hills.AdaptiveClasyHillShading;
2223
import org.mapsforge.map.layer.hills.DemFolderFS;
@@ -154,6 +155,19 @@ public void dispose() {
154155
super.dispose();
155156
}
156157

158+
@Override
159+
protected boolean onKeyDown(int keycode) {
160+
if (keycode == Input.Keys.F5) {
161+
if (themeFile != null) {
162+
mMap.setTheme(new ExternalRenderTheme(themeFile.getAbsolutePath()));
163+
mMap.clearMap();
164+
}
165+
return true;
166+
}
167+
168+
return false;
169+
}
170+
157171
static File getDemFolder(String[] args) {
158172
if (args.length == 0) {
159173
throw new IllegalArgumentException("missing argument: <mapFile>");

0 commit comments

Comments
 (0)