| 157 | } |
| 158 | |
| 159 | void |
| 160 | TrackerContext::goToNextKeyFrame(int time) |
| 161 | { |
| 162 | std::list<TrackMarkerPtr> markers; |
| 163 | |
| 164 | getSelectedMarkers(&markers); |
| 165 | |
| 166 | int maximum = std::numeric_limits<int>::max(); |
| 167 | for (std::list<TrackMarkerPtr> ::iterator it = markers.begin(); it != markers.end(); ++it) { |
| 168 | int t = (*it)->getNextKeyframe(time); |
| 169 | if ( (t != std::numeric_limits<int>::max()) && (t < maximum) ) { |
| 170 | maximum = t; |
| 171 | } |
| 172 | } |
| 173 | if (maximum != std::numeric_limits<int>::max()) { |
| 174 | getNode()->getApp()->setLastViewerUsingTimeline( NodePtr() ); |
| 175 | getNode()->getApp()->getTimeLine()->seekFrame(maximum, false, NULL, eTimelineChangeReasonPlaybackSeek); |
| 176 | } |
| 177 | } |
| 178 | |
| 179 | TrackMarkerPtr |
| 180 | TrackerContext::getMarkerByName(const std::string & name) const |
no test coverage detected