- for (i = current_bbt_points->begin(); i != current_bbt_points->end(); ++i) {
-
- switch ((*i).type) {
- case TempoMap::Bar:
- break;
-
- case TempoMap::Beat:
-
- if ((*i).beat == 1) {
- color = ARDOUR_UI::config()->canvasvar_MeasureLineBar.get();
- } else {
- color = ARDOUR_UI::config()->canvasvar_MeasureLineBeat.get();
-
- if (beat_density > 2.0) {
- /* only draw beat lines if the gaps between beats are large.
- */
- break;
- }
- }
-
- xpos = frame_to_unit ((nframes64_t) (*i).frame);
- line = get_time_line ();
- line->property_x1() = xpos;
- line->property_x2() = xpos;
- line->property_y2() = canvas_height;
- line->property_color_rgba() = color;
- //line->raise_to_top();
- line->show();
- break;
- }
+ if (tempo_lines == 0) {
+ tempo_lines = new TempoLines(*track_canvas, time_line_group, physical_screen_height);