Oh, thanks.
I'm on a VIEW with the markers added by Toolset, so I deleted that part, and added a name to the area.
I have put this code in the JS box of the map.
jQuery(document).ready(function($){
function initMap() {
var mapid = 'carte';
var map = WPViews.view_addon_maps.get_map(mapid);
var cityCoords = [
{lng: 2.3360251, lat:48.9122591},
{lng: 2.3364328, lat:48.9119277},
{lng: 2.3367118, lat:48.9114623},
{lng: 2.3357033, lat:48.9107078},
{lng: 2.3369907, lat:48.9099463},
{lng: 2.3376023, lat:48.9104892},
{lng: 2.3380207, lat:48.910052},
{lng: 2.3386752, lat:48.9105245},
{lng: 2.3395227, lat:48.9113072},
{lng: 2.340263, lat:48.9119982},
{lng: 2.3400377, lat:48.912104},
{lng: 2.3401665, lat:48.9124636},
{lng: 2.3405205, lat:48.9128937},
{lng: 2.3401557, lat:48.9128866},
{lng: 2.3386215, lat:48.9127245},
{lng: 2.337849, lat:48.9125976},
{lng: 2.3360251, lat:48.9122591}
];
var cityArea = new google.maps.Polygon({
paths: cityCoords,
strokeColor: '#0000FF',
strokeOpacity: 1,
strokeWeight: 0,
fillColor: 'orange',
fillOpacity: .5,
title: 'Cordon'
});
attachPolygonInfoWindow(cityArea)
function attachPolygonInfoWindow(polygon) {
var infoWindow = new google.maps.InfoWindow();
google.maps.event.addListener(polygon, 'click', function (e) {
infoWindow.setContent("Quartier Cordon QP093044");
var latLng = e.latLng;
infoWindow.setPosition(latLng);
infoWindow.open(map);
});
}
cityArea.setMap(map);
}
$(document).on('js_event_wpv_addon_maps_init_map_completed', function(event, event_settings) {
initMap();
});
});
It is just brilliant. Thanks for your answer maybe off the scope, it's really what I wanted.
Toolset rules.