Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
0c5c43c8a8
2 changed files with 8 additions and 6 deletions
|
@ -103,7 +103,9 @@ public class Building extends MapObject {
|
|||
|
||||
|
||||
public float interpolation(String hno) {
|
||||
if(getInterpolationType() != null || getInterpolationInterval() > 0 || checkNameAsInterpolation()) {
|
||||
if(getInterpolationType() != null || getInterpolationInterval() > 0
|
||||
//|| checkNameAsInterpolation() // disable due to situation in NL #4284
|
||||
) {
|
||||
int num = Algorithms.extractFirstIntegerNumber(hno);
|
||||
String fname = super.getName();
|
||||
int numB = Algorithms.extractFirstIntegerNumber(fname);
|
||||
|
@ -139,14 +141,13 @@ public class Building extends MapObject {
|
|||
}
|
||||
return -1;
|
||||
}
|
||||
private boolean checkNameAsInterpolation() {
|
||||
|
||||
protected boolean checkNameAsInterpolation() {
|
||||
String nm = super.getName();
|
||||
boolean interpolation = nm.contains("-");
|
||||
if(interpolation) {
|
||||
for(int i = 0; i < nm.length(); i++) {
|
||||
if(nm.charAt(i) >= '0' && nm.charAt(i) <= '9' || nm.charAt(i) == '-') {
|
||||
|
||||
} else {
|
||||
if(!(nm.charAt(i) >= '0' && nm.charAt(i) <= '9') && nm.charAt(i) != '-') {
|
||||
interpolation = false;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -288,8 +288,8 @@ public class AppInitializer implements IProgress {
|
|||
}
|
||||
|
||||
private void indexRegionsBoundaries(List<String> warnings) {
|
||||
File file = app.getAppPath("regions.ocbf");
|
||||
try {
|
||||
File file = app.getAppPath("regions.ocbf");
|
||||
if (file != null) {
|
||||
if (!file.exists()) {
|
||||
Algorithms.streamCopy(OsmandRegions.class.getResourceAsStream("regions.ocbf"),
|
||||
|
@ -300,6 +300,7 @@ public class AppInitializer implements IProgress {
|
|||
}
|
||||
} catch (Exception e) {
|
||||
warnings.add(e.getMessage());
|
||||
file.delete(); // recreate file
|
||||
LOG.error(e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue