commit
c68b154987
3 changed files with 4 additions and 3 deletions
|
@ -67,4 +67,5 @@ public class IndexConstants {
|
||||||
public static final String VOICE_INDEX_DIR = "voice/"; //$NON-NLS-1$
|
public static final String VOICE_INDEX_DIR = "voice/"; //$NON-NLS-1$
|
||||||
public static final String RENDERERS_DIR = "rendering/"; //$NON-NLS-1$
|
public static final String RENDERERS_DIR = "rendering/"; //$NON-NLS-1$
|
||||||
public static final String ROUTING_XML_FILE= "routing.xml";
|
public static final String ROUTING_XML_FILE= "routing.xml";
|
||||||
|
public static final String SETTINGS_DIR = "settings/"; //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
|
|
|
@ -335,8 +335,8 @@ public class AppInitializer implements IProgress {
|
||||||
}
|
}
|
||||||
|
|
||||||
private void initPoiTypes() {
|
private void initPoiTypes() {
|
||||||
if(app.getAppPath("poi_types.xml").exists()) {
|
if (app.getAppPath(IndexConstants.SETTINGS_DIR + "poi_types.xml").exists()) {
|
||||||
app.poiTypes.init(app.getAppPath("poi_types.xml").getAbsolutePath());
|
app.poiTypes.init(app.getAppPath(IndexConstants.SETTINGS_DIR + "poi_types.xml").getAbsolutePath());
|
||||||
} else {
|
} else {
|
||||||
app.poiTypes.init();
|
app.poiTypes.init();
|
||||||
}
|
}
|
||||||
|
|
|
@ -497,7 +497,7 @@ public class ResourceManager {
|
||||||
|
|
||||||
private void copyPoiTypes() {
|
private void copyPoiTypes() {
|
||||||
try {
|
try {
|
||||||
File file = context.getAppPath("poi_types.xml");
|
File file = context.getAppPath(IndexConstants.SETTINGS_DIR + "poi_types.xml");
|
||||||
if (file != null) {
|
if (file != null) {
|
||||||
FileOutputStream fout = new FileOutputStream(file);
|
FileOutputStream fout = new FileOutputStream(file);
|
||||||
Algorithms.streamCopy(MapPoiTypes.class.getResourceAsStream("poi_types.xml"), fout);
|
Algorithms.streamCopy(MapPoiTypes.class.getResourceAsStream("poi_types.xml"), fout);
|
||||||
|
|
Loading…
Reference in a new issue