diff --git a/gtk2_ardour/option_editor.cc b/gtk2_ardour/option_editor.cc index 2b81ff29bc..9dac7918d4 100644 --- a/gtk2_ardour/option_editor.cc +++ b/gtk2_ardour/option_editor.cc @@ -65,7 +65,7 @@ OptionEditor::OptionEditor (ARDOUR_UI& uip, PublicEditor& ed, Mixer_UI& mixui) short_xfade_adjustment (0, 1.0, 500.0, 5.0, 100.0), short_xfade_slider (short_xfade_adjustment), - destructo_xfade_adjustment (0, 1.0, 500.0, 5.0, 100.0), + destructo_xfade_adjustment (1.0, 1.0, 500.0, 1.0, 100.0), destructo_xfade_slider (destructo_xfade_adjustment), /* Sync */ @@ -94,6 +94,7 @@ OptionEditor::OptionEditor (ARDOUR_UI& uip, PublicEditor& ed, Mixer_UI& mixui) click_io_selector = 0; auditioner_io_selector = 0; + session = 0; set_default_size (300, 300); set_title (_("ardour: options editor")); @@ -329,6 +330,11 @@ OptionEditor::setup_fade_options () destructo_xfade_adjustment.signal_value_changed().connect (mem_fun(*this, &OptionEditor::destructo_xfade_adjustment_changed)); + short_xfade_slider.set_update_policy (UPDATE_DISCONTINUOUS); + destructo_xfade_slider.set_update_policy (UPDATE_DISCONTINUOUS); + + destructo_xfade_adjustment.set_value (Config->get_destructive_xfade_msecs()); + fade_packer.show_all (); } diff --git a/libs/ardour/configuration.cc b/libs/ardour/configuration.cc index a7fc6b7dd6..c925525144 100644 --- a/libs/ardour/configuration.cc +++ b/libs/ardour/configuration.cc @@ -265,7 +265,7 @@ Configuration::state (bool user_only) } if (!user_only || destructive_xfade_msecs_is_user) { snprintf(buf, sizeof(buf), "%" PRIu32, destructive_xfade_msecs); - node->add_child_nocopy(option_node("destructive_xfade_msecs", string(buf))); + node->add_child_nocopy(option_node("destructive-xfade-msecs", string(buf))); } /* use-vst is always per-user */ @@ -409,7 +409,7 @@ Configuration::set_state (const XMLNode& root) set_midi_feedback_interval_ms (atoi (option_value.c_str())); } else if (option_name == "latched-record-enable") { set_latched_record_enable (option_value == "yes"); - } else if (option_name == "destructive_xfade_msecs") { + } else if (option_name == "destructive-xfade-msecs") { uint32_t v; if (sscanf (option_value.c_str(), "%u", &v) == 1) { set_destructive_xfade_msecs (v); @@ -1107,6 +1107,11 @@ void Configuration::set_destructive_xfade_msecs (uint32_t msecs, jack_nframes_t rate) { destructive_xfade_msecs = msecs; + + if (user_configuration) { + destructive_xfade_msecs_is_user = true; + } + if (rate) { DestructiveFileSource::setup_standard_crossfades (rate); }