indicate that silence trim is already active.

This commit is contained in:
Robin Gareus 2015-09-19 20:28:56 +02:00
parent c829c10a74
commit dad0e390ff
2 changed files with 11 additions and 2 deletions

View File

@ -91,8 +91,8 @@ StripSilenceDialog::StripSilenceDialog (Session* s, list<RegionView*> const & v)
get_vbox()->pack_start (*hbox, false, false);
add_button (Gtk::Stock::CANCEL, Gtk::RESPONSE_CANCEL);
add_button (Gtk::Stock::APPLY, Gtk::RESPONSE_OK);
cancel_button = add_button (Gtk::Stock::CANCEL, Gtk::RESPONSE_CANCEL);
apply_button = add_button (Gtk::Stock::APPLY, Gtk::RESPONSE_OK);
set_default_response (Gtk::RESPONSE_OK);
get_vbox()->pack_start (_progress_bar, true, true, 12);
@ -141,9 +141,15 @@ StripSilenceDialog::silences (AudioIntervalMap& m)
void
StripSilenceDialog::drop_rects ()
{
// called by parent when starting to progess (dialog::run returned),
// but before the dialog is destoyed.
for (list<ViewInterval>::iterator v = views.begin(); v != views.end(); ++v) {
v->view->drop_silent_frames ();
}
cancel_button->set_sensitive (false);
apply_button->set_sensitive (false);
}
void

View File

@ -66,6 +66,9 @@ private:
AudioClock* _fade_length;
Gtk::ProgressBar _progress_bar;
Gtk::Button* cancel_button;
Gtk::Button* apply_button;
struct ViewInterval {
RegionView* view;
ARDOUR::AudioIntervalResult intervals;