Refactor drawMeasureTrack