X-Git-Url: http://git.cinelerra-gg.org/git/?p=goodguy%2Fhistory.git;a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Ftimebar.C;h=10a095f9546edbb81a97c4a0a10ec38bca83a73c;hp=e386bea54120c4ffb2e6d769aa3a2105ba29a769;hb=d60a59baa6cfe24c0fb153ed9e150a834ba29feb;hpb=c279e21fc2394a7908bbd1ba8c79b116fe9fb14a diff --git a/cinelerra-5.1/cinelerra/timebar.C b/cinelerra-5.1/cinelerra/timebar.C index e386bea5..10a095f9 100644 --- a/cinelerra-5.1/cinelerra/timebar.C +++ b/cinelerra-5.1/cinelerra/timebar.C @@ -309,6 +309,29 @@ void TimeBar::update_highlights() } else if( out_point ) out_point->update(0); + + draw_inout_highlight(); +} + +void TimeBar::draw_inout_highlight() +{ + EDL *edl = get_edl(); + if( !edl->local_session->inpoint_valid() ) return; + if( !edl->local_session->outpoint_valid() ) return; + double in_position = edl->local_session->get_inpoint(); + double out_position = edl->local_session->get_outpoint(); + if( in_position >= out_position ) return; + int in_x = position_to_pixel(in_position); + int out_x = position_to_pixel(out_position); + CLAMP(in_x, 0, get_w()); + CLAMP(out_x, 0, get_w()); + set_color(GREEN); + int lw = 5; + set_line_width(lw); + set_inverse(); + draw_line(in_x, get_h()-2*lw, out_x, get_h()-2*lw); + set_opaque(); + set_line_width(1); } void TimeBar::update_points()