-UI fix for too many redraws, updated dropdown menu of ClipSelector

This commit is contained in:
Harry van Haaren 2013-08-21 23:51:26 +01:00
parent e5dd3bea0d
commit 36454399b6
2 changed files with 11 additions and 4 deletions

View file

@ -334,8 +334,9 @@ class ClipSelector : public Fl_Button
{"8"},
{"16"},
{"32"},
{"64"},
{0},
{ "Record" },
//{ "Record" },
{ "Use as tempo" },
{ 0 }
};
@ -367,6 +368,9 @@ class ClipSelector : public Fl_Button
} else if ( strcmp(m->label(), "32") == 0 ) {
EventLooperLoopLength e = EventLooperLoopLength(ID, clipNum ,32);
writeToDspRingbuffer( &e );
} else if ( strcmp(m->label(), "64") == 0 ) {
EventLooperLoopLength e = EventLooperLoopLength(ID, clipNum ,64);
writeToDspRingbuffer( &e );
}
else if ( strcmp(m->label(), "Use as tempo") == 0 )
{

View file

@ -64,9 +64,12 @@ void handleGuiEvents()
if ( availableRead >= sizeof(EventLooperProgress) ) {
EventLooperProgress ev;
jack_ringbuffer_read( rbToGui, (char*)&ev, sizeof(EventLooperProgress) );
//printf("progress on %i, %f\n", ev.track, ev.progress);
gui->getTrack(ev.track)->radial.value(ev.progress);
//jack->setLooperLoopLength( ev.track, ev.scale );
// only update if significant change
//if ( ev.progress - gui->getTrack(ev.track)->radial.value() >= 0.05 ||
// ev.progress > 0.9 )
gui->getTrack(ev.track)->radial.value(ev.progress);
} break; }
case Event::TRACK_SIGNAL_LEVEL: {