Timeline: Add blinker to indicate that one or more sequence widgets is selected.

Conflicts:

	Timeline/TLE.fl
This commit is contained in:
Jonathan Moore Liles 2010-01-12 02:53:00 -06:00
parent b7087b3132
commit ef0626ae75
4 changed files with 18 additions and 5 deletions

View File

@ -163,7 +163,7 @@ public:
virtual Sequence_Widget *clone ( void ) const = 0; virtual Sequence_Widget *clone ( void ) const = 0;
bool selected ( void ) const; bool selected ( void ) const;
int nselected ( void ) const static int nselected ( void )
{ return _selection.size(); } { return _selection.size(); }
void select ( void ); void select ( void );
void deselect ( void ); void deselect ( void );

View File

@ -131,8 +131,7 @@ if ( Project::open() )
update_menu(); update_menu();
project_name->redraw();} {selected project_name->redraw();} {}
}
} }
Function {run()} {} { Function {run()} {} {
code {update_menu(); code {update_menu();
@ -683,6 +682,12 @@ ab.run();}
code0 {\#include "FL/Fl_Blinker.H"} code0 {\#include "FL/Fl_Blinker.H"}
class Fl_Blinker class Fl_Blinker
} }
Fl_Button selected_blinker {
label SEL
xywh {695 50 50 15} box ROUNDED_BOX down_box ROUNDED_BOX color 13 selection_color 5 labelfont 2 labelcolor 39 deactivate
code0 {\#include "FL/Fl_Blinker.H"}
class Fl_Blinker
}
Fl_Box stats_box { Fl_Box stats_box {
label {<stats>} label {<stats>}
xywh {810 1 215 21} labelsize 13 labelcolor 53 align 88 xywh {810 1 215 21} labelsize 13 labelcolor 53 align 88
@ -789,7 +794,9 @@ if ( engine->zombified() && ! zombie )
solo_blinker->value( Track::soloing() ); solo_blinker->value( Track::soloing() );
rec_blinker->value( transport->rolling && transport->rec_enabled() ); rec_blinker->value( transport->rolling && transport->rec_enabled() );
lash_blinker->value( lash->enabled() );} {} lash_blinker->value( lash->enabled() );
selected_blinker->value( timeline->nselected() );} {selected
}
} }
Function {update_cb( void *v )} {open private return_type {static void} Function {update_cb( void *v )} {open private return_type {static void}
} { } {

View File

@ -1129,6 +1129,12 @@ Timeline::select_none ( void )
Sequence_Widget::select_none(); Sequence_Widget::select_none();
} }
int
Timeline::nselected ( void ) const
{
return Sequence_Widget::nselected();
}
/** An unfortunate necessity for implementing our own DND aside from /** An unfortunate necessity for implementing our own DND aside from
* the (bogus) native FLTK system */ * the (bogus) native FLTK system */
Track * Track *

View File

@ -185,7 +185,7 @@ public:
void select( const Rectangle &r ); void select( const Rectangle &r );
Track * track_under ( int Y ); Track * track_under ( int Y );
int nselected ( void ) const;
void delete_selected ( void ); void delete_selected ( void );
void select_none ( void ); void select_none ( void );