Add BasicUI::transport_rolling()

Now this name directly corresponds to the session method it wraps.

Towards removing the direct use of Session by surfaces.
This commit is contained in:
David Robillard 2021-06-16 00:40:08 -04:00
parent def143bc64
commit a48cddf235
5 changed files with 11 additions and 4 deletions

View file

@ -440,6 +440,12 @@ BasicUI::get_transport_speed () const
return _session->actual_speed ();
}
bool
BasicUI::transport_rolling () const
{
return _session->transport_rolling ();
}
bool
BasicUI::transport_stopped_or_stopping () const
{

View file

@ -70,6 +70,7 @@ class LIBCONTROLCP_API BasicUI {
void set_transport_speed (double speed);
double get_transport_speed () const;
bool transport_rolling() const;
bool transport_stopped_or_stopping () const;
bool get_play_loop () const;

View file

@ -713,7 +713,7 @@ LaunchControlXL::notify_transport_state_changed ()
{ /*
Button* b = id_button_map[Play];
if (_session->transport_rolling()) {
if (transport_rolling ()) {
b->set_state (LED::OneShot24th);
b->set_color (LED::GreenFull);
} else {

View file

@ -360,7 +360,7 @@ Push2::button_play ()
}
if (_modifier_state & ModShift) {
goto_start (_session->transport_rolling());
goto_start (transport_rolling ());
return;
}
@ -375,7 +375,7 @@ Push2::button_play ()
return;
}
if (_session->transport_rolling ()) {
if (transport_rolling ()) {
transport_stop ();
} else {
transport_play ();

View file

@ -909,7 +909,7 @@ Push2::notify_transport_state_changed ()
{
boost::shared_ptr<Button> b = id_button_map[Play];
if (_session->transport_rolling()) {
if (transport_rolling ()) {
b->set_state (LED::OneShot24th);
b->set_color (LED::Green);
} else {