Sequencer: Replace pattern number spinner with value slider.
This commit is contained in:
parent
46d2324446
commit
68655cc599
|
@ -471,8 +471,6 @@ else
|
||||||
Fl_Tabs tabs {
|
Fl_Tabs tabs {
|
||||||
callback {((Fl_Group*)o->value())->child( 0 )->take_focus();
|
callback {((Fl_Group*)o->value())->child( 0 )->take_focus();
|
||||||
|
|
||||||
ui->pan_indicators->show();
|
|
||||||
|
|
||||||
if ( o->value() == pattern_tab )
|
if ( o->value() == pattern_tab )
|
||||||
pattern_canvas_widget->handle_pan();
|
pattern_canvas_widget->handle_pan();
|
||||||
else if ( o->value() == phrase_tab )
|
else if ( o->value() == phrase_tab )
|
||||||
|
@ -480,8 +478,6 @@ else if ( o->value() == phrase_tab )
|
||||||
|
|
||||||
if ( o->value() != pattern_tab )
|
if ( o->value() != pattern_tab )
|
||||||
{
|
{
|
||||||
if ( o->value() != phrase_tab )
|
|
||||||
ui->pan_indicators->hide();
|
|
||||||
edit_menu->deactivate();
|
edit_menu->deactivate();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -490,7 +486,7 @@ else
|
||||||
}
|
}
|
||||||
|
|
||||||
menu_bar->redraw();} open
|
menu_bar->redraw();} open
|
||||||
xywh {0 79 865 698} box BORDER_BOX color 47 labeltype SHADOW_LABEL labelsize 19 when 1 resizable
|
xywh {0 79 865 711} box BORDER_BOX color 47 labeltype SHADOW_LABEL labelsize 19 when 1 resizable
|
||||||
code0 {canvas_background_color = fl_rgb_color( 18, 18, 18 );}
|
code0 {canvas_background_color = fl_rgb_color( 18, 18, 18 );}
|
||||||
} {
|
} {
|
||||||
Fl_Group sequence_tab {
|
Fl_Group sequence_tab {
|
||||||
|
@ -674,7 +670,7 @@ o->maximum( phrase::phrases() );}
|
||||||
}
|
}
|
||||||
Fl_Group pattern_tab {
|
Fl_Group pattern_tab {
|
||||||
label Pattern open
|
label Pattern open
|
||||||
xywh {0 102 865 674} box FLAT_BOX color 47
|
xywh {0 102 865 688} box FLAT_BOX color 47
|
||||||
code0 {update_pattern_widgets();}
|
code0 {update_pattern_widgets();}
|
||||||
} {
|
} {
|
||||||
Fl_Box pattern_canvas_widget {
|
Fl_Box pattern_canvas_widget {
|
||||||
|
@ -687,7 +683,7 @@ o->maximum( phrase::phrases() );}
|
||||||
class O_Canvas
|
class O_Canvas
|
||||||
}
|
}
|
||||||
Fl_Group {} {open
|
Fl_Group {} {open
|
||||||
xywh {0 694 862 78} box FLAT_BOX color 47
|
xywh {0 694 862 96} box FLAT_BOX color 47
|
||||||
} {
|
} {
|
||||||
Fl_Input pattern_name_field {
|
Fl_Input pattern_name_field {
|
||||||
label {name:}
|
label {name:}
|
||||||
|
@ -696,18 +692,6 @@ o->maximum( phrase::phrases() );}
|
||||||
code0 {o->up_box( FL_ROUNDED_BOX );}
|
code0 {o->up_box( FL_ROUNDED_BOX );}
|
||||||
class Fl_Sometimes_Input
|
class Fl_Sometimes_Input
|
||||||
}
|
}
|
||||||
Fl_Spinner pattern_number_spinner {
|
|
||||||
label {Pattern:}
|
|
||||||
callback {pattern *p = ((pattern *)pattern_c->grid())->by_number( o->value() );
|
|
||||||
|
|
||||||
if ( p )
|
|
||||||
pattern_c->grid( p );
|
|
||||||
|
|
||||||
o->maximum( pattern::patterns() );}
|
|
||||||
xywh {165 704 55 24} color 36 labelsize 9 align 1 when 1
|
|
||||||
code0 {o->maximum( 1 );}
|
|
||||||
code1 {// pattern::signal_create_destroy.connect( sigc::mem_fun( o, static_cast<void (Fl_Spinner::*)(double)>(&Fl_Spinner::maximum) ) );}
|
|
||||||
}
|
|
||||||
Fl_Light_Button pattern_mute_button {
|
Fl_Light_Button pattern_mute_button {
|
||||||
label Mute
|
label Mute
|
||||||
callback {Grid *g = pattern_c->grid();
|
callback {Grid *g = pattern_c->grid();
|
||||||
|
@ -717,7 +701,7 @@ g->mode( g->mode() == MUTE ? PLAY : MUTE );
|
||||||
o->value( g->mode() == MUTE );
|
o->value( g->mode() == MUTE );
|
||||||
|
|
||||||
pattern_solo_button->value( 0 );}
|
pattern_solo_button->value( 0 );}
|
||||||
xywh {10 738 65 25} type Normal color 37
|
xywh {167 704 60 25} type Normal color 37
|
||||||
}
|
}
|
||||||
Fl_Light_Button pattern_solo_button {
|
Fl_Light_Button pattern_solo_button {
|
||||||
label Solo
|
label Solo
|
||||||
|
@ -728,12 +712,12 @@ g->mode( g->mode() == SOLO ? PLAY : SOLO );
|
||||||
o->value( g->mode() == SOLO );
|
o->value( g->mode() == SOLO );
|
||||||
|
|
||||||
pattern_mute_button->value( 0 );}
|
pattern_mute_button->value( 0 );}
|
||||||
xywh {80 738 65 25} type Normal color 37
|
xywh {167 744 60 25} type Normal color 37
|
||||||
}
|
}
|
||||||
Fl_Text_Editor pattern_notes_edit {
|
Fl_Text_Editor pattern_notes_edit {
|
||||||
label {Notes:}
|
label {Notes:}
|
||||||
callback {pattern_c->grid()->notes( o->buffer()->text() );}
|
callback {pattern_c->grid()->notes( o->buffer()->text() );}
|
||||||
xywh {230 713 227 48} selection_color 48 labelsize 12 textcolor 94 resizable
|
xywh {235 710 222 58} selection_color 48 labelsize 12 textcolor 94 resizable
|
||||||
code0 {o->buffer( pattern_notes_buffer = new Fl_Text_Buffer );}
|
code0 {o->buffer( pattern_notes_buffer = new Fl_Text_Buffer );}
|
||||||
}
|
}
|
||||||
Fl_Group pattern_settings_group {open
|
Fl_Group pattern_settings_group {open
|
||||||
|
@ -946,6 +930,16 @@ pattern_c->changed_mapping();}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Fl_Value_Slider pattern_number_spinner {
|
||||||
|
label Pattern
|
||||||
|
callback {pattern *p = ((pattern *)pattern_c->grid())->by_number( o->value() );
|
||||||
|
|
||||||
|
if ( p )
|
||||||
|
pattern_c->grid( p );
|
||||||
|
|
||||||
|
o->maximum( pattern::patterns() );} selected
|
||||||
|
xywh {5 744 155 24} type Horizontal labelsize 10 align 1 minimum 1 maximum 128 step 1 value 1 textsize 14
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -977,26 +971,6 @@ if ( s != o->label() )
|
||||||
xywh {783 776 82 31} box THIN_UP_BOX align 64
|
xywh {783 776 82 31} box THIN_UP_BOX align 64
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Fl_Group pan_indicators {open
|
|
||||||
xywh {370 692 120 20}
|
|
||||||
} {
|
|
||||||
Fl_Box scroll_up_box {
|
|
||||||
label {@2<}
|
|
||||||
xywh {400 694 30 18}
|
|
||||||
}
|
|
||||||
Fl_Box scroll_down_box {
|
|
||||||
label {@2>}
|
|
||||||
xywh {430 694 30 18}
|
|
||||||
}
|
|
||||||
Fl_Box scroll_left_box {
|
|
||||||
label {@<}
|
|
||||||
xywh {370 692 30 18} hide
|
|
||||||
}
|
|
||||||
Fl_Box scroll_right_box {
|
|
||||||
label {@>}
|
|
||||||
xywh {460 692 30 18} hide
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Fl_Group {} {open
|
Fl_Group {} {open
|
||||||
xywh {0 0 865 31}
|
xywh {0 0 865 31}
|
||||||
} {
|
} {
|
||||||
|
@ -1740,28 +1714,6 @@ _border_drawn = true;} {}
|
||||||
}
|
}
|
||||||
Function {handle_pan( void )} {open return_type void
|
Function {handle_pan( void )} {open return_type void
|
||||||
} {
|
} {
|
||||||
code {int up, left, right, down;
|
|
||||||
|
|
||||||
if ( ! ui )
|
|
||||||
return;
|
|
||||||
_c->can_scroll( &left, &right, &up, &down );
|
|
||||||
|
|
||||||
if ( left == 0 )
|
|
||||||
ui->scroll_left_box->hide();
|
|
||||||
else
|
|
||||||
ui->scroll_left_box->show();
|
|
||||||
|
|
||||||
if ( up == 0 )
|
|
||||||
ui->scroll_up_box->hide();
|
|
||||||
else
|
|
||||||
ui->scroll_up_box->show();
|
|
||||||
|
|
||||||
if ( down == 0 )
|
|
||||||
ui->scroll_down_box->hide();
|
|
||||||
else
|
|
||||||
ui->scroll_down_box->show();
|
|
||||||
|
|
||||||
ui->scroll_right_box->hide();} {}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue