1
0
Fork 0
forked from 0x2620/oxjs

listmap bugfixes

This commit is contained in:
rolux 2011-05-24 18:22:37 +02:00
commit 11e98db160
2 changed files with 15 additions and 19 deletions

View file

@ -155,16 +155,10 @@ Ox.load.Geo = function(options, callback) {
return country;
};
/*@
Ox.reverseGeoname <f> Reverses a geoname
@*/
Ox.reverseGeoname = function(geoname) {
return geoname
.replace('Bonaire, Saint Eustatius and Saba', 'Bonaire Saint Eustatius and Saba')
.split(', ')
.reverse()
.join(', ')
.replace('Bonaire Saint Eustatius and Saba', 'Bonaire, Saint Eustatius and Saba');
Ox.getImageByGeoname = function(type, size, geoname) {
var country = Ox.getCountryByGeoname(geoname),
code = country ? country.code : 'NTHH';
return Ox.PATH + 'Ox.Geo/png/' + type + 's/' + size + '/' + code + '.png';
};
callback(true);