Changeset 335 in tmcsimulator for trunk/webapps/js
- Timestamp:
- 03/19/2019 01:17:33 PM (7 years ago)
- Location:
- trunk/webapps/js
- Files:
-
- 2 edited
-
cctvLayer.js (modified) (2 diffs)
-
cmsLayer.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/webapps/js/cctvLayer.js
r326 r335 43 43 cctvLayer = new google.maps.Data(); 44 44 cctvLayer.loadGeoJson(kCCTVfile); 45 // Define the clickable area on an icon (the default is too big) 46 var clickRegion = {coords: [0,0,14,8], type: "rect"} 45 47 cctvLayer.setStyle(function(feature) 46 48 { … … 48 50 return { 49 51 icon: makecctvIcon(feature.getProperty("nearVDS")), 52 shape: clickRegion, 50 53 title: feature.getId() + " " +feature.getProperty('locationName'), 51 54 visible: false -
trunk/webapps/js/cmsLayer.js
r334 r335 34 34 cmsLayer = new google.maps.Data(); 35 35 cmsLayer.setMap(map); 36 cmsLayer.loadGeoJson(kCMSfile); 36 cmsLayer.loadGeoJson(kCMSfile); 37 // Define the clickable area on a CMS icon (the default is too big) 38 var clickRegion = {coords: [0,0,18,15], type: "rect"} 37 39 cmsLayer.setStyle(function(feature) 38 { 39 // return the StyleOptions 40 return { 41 icon: iconCMSidle, 42 title: feature.getId()+ " " +feature.getProperty("location")+ " " 43 + feature.getProperty("street"), 44 visible: false 45 }; 46 }); 40 { 41 // return the StyleOptions 42 return { 43 icon: iconCMSidle, 44 shape: clickRegion, 45 title: feature.getId()+ " " +feature.getProperty("location")+ " " 46 + feature.getProperty("street"), 47 visible: false 48 }; 49 }); 47 50 48 51 cmsLayer.addListener('click', function(event)
Note: See TracChangeset
for help on using the changeset viewer.
