forked from 0x2620/oxjs
geo/map bugfixes
This commit is contained in:
parent
b6c74551fa
commit
dfd2787438
14 changed files with 892 additions and 809 deletions
|
|
@ -58,7 +58,7 @@ Ox.ListMap = function(options, self) {
|
|||
format: function(value, data) {
|
||||
return $('<img>')
|
||||
.attr({
|
||||
src: Ox.getFlagByGeoname(data.name, 16)
|
||||
src: Ox.getFlagByGeoname(data.geoname, 16)
|
||||
})
|
||||
.css({
|
||||
width: '14px',
|
||||
|
|
|
|||
|
|
@ -840,10 +840,10 @@ Ox.Map = function(options, self) {
|
|||
|
||||
self.places = [];
|
||||
if (!self.isAsync) {
|
||||
self.options.places.forEach(function(place, i) {
|
||||
self.places[i] = new Ox.MapPlace(Ox.extend({
|
||||
self.options.places.forEach(function(place) {
|
||||
self.places.push(new Ox.MapPlace(Ox.extend({
|
||||
map: that
|
||||
}, place));
|
||||
}, place)));
|
||||
});
|
||||
}
|
||||
google.maps.event.trigger(self.map, 'resize');
|
||||
|
|
|
|||
|
|
@ -206,15 +206,15 @@ Ox.MapMarker = function(options) {
|
|||
//Ox.Log('Map', 'setOptions, that.map: ', that.map)
|
||||
if (that.map.options('showTypes')) {
|
||||
that.color = typeColor[that.place.type];
|
||||
that.size = 8;
|
||||
Ox.forEach(areaSize, function(size, area) {
|
||||
if (that.place.area > area) {
|
||||
that.size = size;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
that.size = 8;
|
||||
Ox.forEach(areaSize, function(size, area) {
|
||||
if (that.place.area > area) {
|
||||
that.size = size;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
that.marker.setOptions({
|
||||
// fixme: cursor remains pointer
|
||||
cursor: that.place.editing ? 'move' : 'pointer',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue