Add menu option to insert program changes.
[ardour.git] / gtk2_ardour / time_fx_dialog.cc
index 34fe6e932df977e59e1ab848159b873f3332afa2..f166768834517130f2f5ab549ac78ab59c03f706 100644 (file)
@@ -29,7 +29,6 @@
 #include "pbd/pthread_utils.h"
 #include "pbd/memento_command.h"
 
-#include <gtkmm2ext/window_title.h>
 #include <gtkmm2ext/utils.h>
 
 #include "editor.h"
@@ -42,7 +41,6 @@
 #include "ardour/audioplaylist.h"
 #include "ardour/audio_track.h"
 #include "ardour/audioregion.h"
-#include "ardour/audio_diskstream.h"
 #include "ardour/stretch.h"
 #include "ardour/midi_stretch.h"
 #include "ardour/pitch.h"
@@ -57,7 +55,6 @@ using namespace RubberBand;
 using namespace std;
 using namespace ARDOUR;
 using namespace PBD;
-using namespace sigc;
 using namespace Gtk;
 using namespace Gtkmm2ext;
 
@@ -83,13 +80,11 @@ TimeFXDialog::TimeFXDialog (Editor& e, bool pitch)
        set_position (Gtk::WIN_POS_MOUSE);
        set_name (N_("TimeFXDialog"));
 
-       WindowTitle title(Glib::get_application_name());
        if (pitching) {
-               title += _("Pitch Shift");
+               set_title (_("Pitch Shift"));
        } else {
-               title += _("Time Stretch");
+               set_title (_("Time Stretch"));
        }
-       set_title(title.get_string());
 
        cancel_button = add_button (Gtk::Stock::CANCEL, Gtk::RESPONSE_CANCEL);
 
@@ -150,7 +145,7 @@ TimeFXDialog::TimeFXDialog (Editor& e, bool pitch)
 
                set_popdown_strings (stretch_opts_selector, editor.rb_opt_strings);
                /* set default */
-               stretch_opts_selector.set_active_text (editor.rb_opt_strings[4]);
+               stretch_opts_selector.set_active_text (editor.rb_opt_strings[editor.rb_current_opt]);
                table->attach (stretch_opts_selector, 2, 3, 0, 1, Gtk::FILL, Gtk::EXPAND & Gtk::FILL, 0, 0);
 
                table->attach (precise_button, 1, 3, 1, 2, Gtk::FILL, Gtk::EXPAND, 0, 0);
@@ -175,8 +170,6 @@ TimeFXDialog::TimeFXDialog (Editor& e, bool pitch)
        l = manage (new Label (_("<b>Progress</b>"), Gtk::ALIGN_LEFT, Gtk::ALIGN_CENTER, false));
        l->set_use_markup ();
 
-       progress_bar.set_name (N_("TimeFXProgress"));
-
        progress_box->pack_start (*l, false, false);
        progress_box->pack_start (progress_bar, false, true);