Changeset 1589427
- Timestamp:
- 02/05/2017 06:06:35 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
scale-lite-tools/trunk/assets/js/frontend.sl-google-maps.js
r1589400 r1589427 41 41 }); 42 42 43 function addMarker(position, title, icon ) {43 function addMarker(position, title, icon, color) { 44 44 var marker = new google.maps.Marker({ 45 45 position: position, 46 46 map: map, 47 icon: 48 { 49 url: '/wp-content/plugins/trunk/assets/map-svg-icons/ic_'+icon+'_48px.svg', 50 scaledSize: new google.maps.Size(48, 48) 47 icon: ' ', 48 label: { 49 fontFamily: 'Material Icons', 50 fontSize: '3.5em', 51 color: color, 52 text: icon 51 53 } 52 54 }); … … 71 73 i]].icon) ? scaleLiteMarkersBuffer[mapObject.map_markers[ 72 74 i]].icon : 'place' 75 var marker_color = (scaleLiteMarkersBuffer[mapObject.map_markers[ 76 i]].icon_color) ? scaleLiteMarkersBuffer[mapObject.map_markers[ 77 i]].icon_color : '#3E82F7' 73 78 74 addMarker({lat: marker_lat, lng: marker_lng}, title+description, marker_icon );79 addMarker({lat: marker_lat, lng: marker_lng}, title+description, marker_icon, marker_color); 75 80 } 76 81 }
Note: See TracChangeset
for help on using the changeset viewer.