merging changes
This commit is contained in:
parent
7968a11116
commit
69317c3673
1 changed files with 19 additions and 4 deletions
|
@ -21,18 +21,33 @@ Ox.MapMarker = function(options) {
|
||||||
|
|
||||||
var that = this,
|
var that = this,
|
||||||
typeColor = {
|
typeColor = {
|
||||||
country: [0, 0, 255],
|
country: [64, 64, 255],
|
||||||
region: [128, 0, 255],
|
region: [128, 0, 255],
|
||||||
city: [255, 0, 0],
|
city: [255, 0, 0],
|
||||||
borough: [255, 128, 0],
|
borough: [255, 128, 0],
|
||||||
street: [255, 255, 0],
|
street: [255, 255, 0],
|
||||||
premise: [128, 255, 0],
|
premise: [128, 255, 0],
|
||||||
feature: [0, 255, 0],
|
feature: [0, 192, 0],
|
||||||
other: [128, 128, 128]
|
other: [128, 128, 128]
|
||||||
|
},
|
||||||
|
areaSize = {
|
||||||
|
100: 10,
|
||||||
|
10000: 12, // 100 m
|
||||||
|
1000000: 14, // 1 km
|
||||||
|
100000000: 16, // 10 km
|
||||||
|
10000000000: 18, // 100 km
|
||||||
|
1000000000000: 20, // 1,000 km
|
||||||
|
100000000000000: 22, // 10,000 km
|
||||||
};
|
};
|
||||||
Ox.print('TYPE:', options.place.type)
|
|
||||||
if (typeColor[options.place.type]) {
|
if (options.map.options('showTypes')) {
|
||||||
options.color = typeColor[options.place.type];
|
options.color = typeColor[options.place.type];
|
||||||
|
options.size = 8;
|
||||||
|
Ox.forEach(areaSize, function(size, area) {
|
||||||
|
if (options.place.area > area) {
|
||||||
|
options.size = size;
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
Ox.forEach(options, function(val, key) {
|
Ox.forEach(options, function(val, key) {
|
||||||
|
|
Loading…
Reference in a new issue