Merge pull request #14 from jmakovicka/start-without-tiles-exception

fix NullPointerException at startup without the tiles directory
This commit is contained in:
Victor Shcherb 2011-06-05 14:39:10 -07:00
commit 458e07c645

View file

@ -69,6 +69,9 @@ public class MapPanel extends JPanel implements IMapDownloaderCallback {
for(TileSourceTemplate t : list){
map.put(t.getName(), t);
}
if (!dir.isDirectory()) {
return map;
}
for(File f : dir.listFiles()){
if(f.isDirectory()){
if(map.containsKey(f.getName())){