+ if (!ARDOUR_UI::instance()->session_loaded) {
+ // engine is not running, no session loaded -> anything goes.
+ allow_to_set_rate = true;
+ } else if (_desired_sample_rate > 0 && get_rate () != _desired_sample_rate) {
+ // only allow to change if the current setting is not the native session rate.
+ allow_to_set_rate = true;
+ }