Browse Source

Refine the playhead.

tags/non-daw-v1.1.0
Jonathan Moore Liles 17 years ago
parent
commit
a7483f7c2d
1 changed files with 26 additions and 1 deletions
  1. +26
    -1
      Timeline/Timeline.C

+ 26
- 1
Timeline/Timeline.C View File

@@ -532,12 +532,15 @@ Timeline::draw_playhead ( void )
if ( x < tracks->x() + Track::width() || x > tracks->x() + tracks->w() ) if ( x < tracks->x() + Track::width() || x > tracks->x() + tracks->w() )
return; return;



fl_color( FL_RED ); fl_color( FL_RED );


int y = rulers->y() + rulers->h(); int y = rulers->y() + rulers->h();
int h = this->h() - hscroll->h(); int h = this->h() - hscroll->h();


fl_rectf( x - 2, y, 5, 2 );
fl_push_clip( Track::width(), y, tracks->w(), h );

// fl_rectf( x - 2, y, 5, 2 );


fl_line( x, y, x, h ); fl_line( x, y, x, h );


@@ -549,6 +552,28 @@ Timeline::draw_playhead ( void )


fl_line( x + 1, y, x + 1, h ); fl_line( x + 1, y, x + 1, h );


/* draw cap */
fl_color( FL_RED );
fl_begin_polygon();

fl_vertex( x - 8, y );
fl_vertex( x, y + 8 );
fl_vertex( x + 8, y );

fl_end_polygon();


/* draw cap outline */
fl_color( FL_BLACK );
fl_begin_line();

fl_vertex( x - 8, y );
fl_vertex( x, y + 8 );
fl_vertex( x + 8, y );

fl_end_line();

fl_pop_clip();
} }


void void


Loading…
Cancel
Save