Removed some TODO's

This commit is contained in:
Michael R. Fisher 2011-10-23 04:52:30 -05:00
parent 0aa3ca76d1
commit 1bb584f895

View file

@ -35,8 +35,7 @@ TimelineViewWindow::TimelineViewWindow (Offset offset, int64_t scale)
: timeOffset(offset)
, timeScale(scale)
{
TODO("Create a function to limit timescale between 1 and MaxScale");
TODO("TICKET #795 Some functions need to be private");
}
Offset
@ -90,7 +89,7 @@ TimelineViewWindow::zoom_view(int point, double time_scale_ratio)
{
// Apply the smoothing factor
int64_t new_time_scale =
(int64_t)( pow(time_scale_ratio, TimelineWidget::ZoomSmoothing) *
(int64_t)(pow(time_scale_ratio, TimelineWidget::ZoomSmoothing) *
(double)TimelineWidget::MaxScale);
/* Prevent Zooming in To Close and Far */
@ -102,8 +101,8 @@ TimelineViewWindow::zoom_view(int point, double time_scale_ratio)
// The view must be shifted so that the zoom is centred on the cursor
TimeVar newStartPoint = get_time_offset();
newStartPoint += TimeValue(point * (timeScale - new_time_scale));
set_time_offset(newStartPoint);
newStartPoint += TimeValue (point * (timeScale - new_time_scale));
set_time_offset (newStartPoint);
// Apply the new scale
set_time_scale(new_time_scale);
@ -112,13 +111,13 @@ TimelineViewWindow::zoom_view(int point, double time_scale_ratio)
void
TimelineViewWindow::shift_view(int view_width, int shift_size)
{
set_time_offset(timeOffset + TimeValue(timeScale * shift_size * view_width / 256));
set_time_offset (timeOffset + TimeValue(timeScale * shift_size * view_width / 256));
}
int
TimelineViewWindow::time_to_x(TimeValue const& time) const
{
return int(_raw(time - timeOffset) / timeScale); //////TODO protect against values out-of range
return int (_raw(time - timeOffset) / timeScale); //////TODO protect against values out-of range
}
Time