Changeset 581 in tmcsimulator for trunk/webapps
- Timestamp:
- 02/06/2020 01:41:46 PM (6 years ago)
- File:
-
- 1 edited
-
trunk/webapps/GTEC/js/vdsLayer.js (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/webapps/GTEC/js/vdsLayer.js
r579 r581 162 162 163 163 // Assemble the line to be written to the events file 164 var lineOut = "101 " + printableTime + "\t" + first[0] + "\t" +165 first[1] + "\t" + first[2]+ "\t" + range.toFixed(3) + "\t"164 var lineOut = "101\t" + printableTime + "\t" + first[0] + "\t" + 165 first[1] + "\t" + Number(first[2]).toFixed(2) + "\t" + range.toFixed(3) + "\t" 166 166 + getColorAbbr(chosenColor); 167 167 … … 242 242 postmileList.push(feature.getId()); // save the postmile in a list 243 243 }); 244 // update the dot colors from the dynamic json data245 updateVDSlayer();246 244 // go adjust the marker coordinates so dots don't overlap 247 245 adjustCoords(calcDistanceFactor()); … … 300 298 } 301 299 } 302 }303 304 // Load the highways dynamic json file and update the map305 function updateVDSlayer()306 {307 eventIndex = -1;308 var parsed_JSON;309 loadJSON(kVDSstatusFile, function(response)310 {311 // Parse JSON string into object312 parsed_JSON = JSON.parse(response);313 // Process each new marker - lookup in current map314 parsed_JSON.features.forEach(updateMarker);315 });316 300 } 317 301
Note: See TracChangeset
for help on using the changeset viewer.
