Plugin Directory

Changeset 1589427


Ignore:
Timestamp:
02/05/2017 06:06:35 PM (9 years ago)
Author:
ionutmorariu
Message:

CHG: use the google icon font instead of svg files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • scale-lite-tools/trunk/assets/js/frontend.sl-google-maps.js

    r1589400 r1589427  
    4141      });
    4242
    43       function addMarker(position, title, icon) {
     43      function addMarker(position, title, icon, color) {
    4444        var marker = new google.maps.Marker({
    4545          position: position,
    4646          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
    5153          }
    5254        });
     
    7173          i]].icon) ? scaleLiteMarkersBuffer[mapObject.map_markers[
    7274          i]].icon : 'place'
     75        var marker_color = (scaleLiteMarkersBuffer[mapObject.map_markers[
     76          i]].icon_color) ? scaleLiteMarkersBuffer[mapObject.map_markers[
     77          i]].icon_color : '#3E82F7'
    7378
    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);
    7580      }
    7681    }
Note: See TracChangeset for help on using the changeset viewer.