Optimize TrafficView code

Speed calculation more accurate; some general code clean-up