Move the labels in the track according to the given TimeWarper. (If necessary this could be optimised by ignoring labels that occur before a specified time, as in most cases they don't need to move.)
| 323 | // (If necessary this could be optimised by ignoring labels that occur before a |
| 324 | // specified time, as in most cases they don't need to move.) |
| 325 | void LabelTrack::WarpLabels(const TimeWarper &warper) { |
| 326 | for (auto &labelStruct: mLabels) { |
| 327 | labelStruct.selectedRegion.setTimes( |
| 328 | warper.Warp(labelStruct.getT0()), |
| 329 | warper.Warp(labelStruct.getT1())); |
| 330 | } |
| 331 | |
| 332 | // This should not be needed, assuming the warper is nondecreasing, but |
| 333 | // let's not assume too much. |
| 334 | SortLabels(); |
| 335 | } |
| 336 | |
| 337 | LabelStruct::LabelStruct(const SelectedRegion ®ion, |
| 338 | const wxString& aTitle) |
no test coverage detected