Fix #27879: sequencer didn't draw overlapping strips well, selected were drawn
authorBrecht Van Lommel <brechtvanlommel@pandora.be>
Wed, 6 Jul 2011 13:15:22 +0000 (13:15 +0000)
committerBrecht Van Lommel <brechtvanlommel@pandora.be>
Wed, 6 Jul 2011 13:15:22 +0000 (13:15 +0000)
under unselected, and active strips red border color for active strips was not
clear enough.

source/blender/editors/space_sequencer/sequencer_draw.c

index 119c5da309ee892e43100814017f9227566292c4..594d2942e8faa5abd02bb316ee236a886c26fd73 100644 (file)
@@ -643,10 +643,12 @@ static void draw_seq_strip(Scene *scene, ARegion *ar, Sequence *seq, int outline
        if (G.moving && (seq->flag & SELECT)) {
                if(seq->flag & SEQ_OVERLAP) {
                        col[0]= 255; col[1]= col[2]= 40;
        if (G.moving && (seq->flag & SELECT)) {
                if(seq->flag & SEQ_OVERLAP) {
                        col[0]= 255; col[1]= col[2]= 40;
-               } else UI_GetColorPtrBlendShade3ubv(col, col, col, 0.0, 120);
+               }
+               else
+                       UI_GetColorPtrBlendShade3ubv(col, col, col, 0.0, 120+outline_tint);
        }
        }
-
-       UI_GetColorPtrBlendShade3ubv(col, col, col, 0.0, outline_tint);
+       else
+               UI_GetColorPtrBlendShade3ubv(col, col, col, 0.0, outline_tint);
        
        glColor3ubv((GLubyte *)col);
        
        
        glColor3ubv((GLubyte *)col);
        
@@ -969,7 +971,7 @@ static void draw_seq_strips(const bContext *C, Editing *ed, ARegion *ar)
                /* loop through strips, checking for those that are visible */
                for (seq= ed->seqbasep->first; seq; seq= seq->next) {
                        /* boundbox and selection tests for NOT drawing the strip... */
                /* loop through strips, checking for those that are visible */
                for (seq= ed->seqbasep->first; seq; seq= seq->next) {
                        /* boundbox and selection tests for NOT drawing the strip... */
-                       if ((seq->flag & SELECT) == sel) continue;
+                       if ((seq->flag & SELECT) != sel) continue;
                        else if (seq == last_seq) continue;
                        else if (MIN2(seq->startdisp, seq->start) > v2d->cur.xmax) continue;
                        else if (MAX2(seq->enddisp, seq->start+seq->len) < v2d->cur.xmin) continue;
                        else if (seq == last_seq) continue;
                        else if (MIN2(seq->startdisp, seq->start) > v2d->cur.xmax) continue;
                        else if (MAX2(seq->enddisp, seq->start+seq->len) < v2d->cur.xmin) continue;