From 65c8d673a2f88db61c68bf119f9dccbe82efd9ff Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Wed, 18 Jan 2012 21:56:06 +0000 Subject: restore ability to create TOC and CUE files during export. this is an option in a given export format, not a per-export choice. so you need export formats with them set (or not) in order to utilize this choice. the resulting CUE/TOC files have not been checked with a burner (e.g. cdrdao) and testing of them would be appreciated - i (paul) have no CD burner h/w git-svn-id: svn://localhost/ardour2/branches/3.0@11266 d708f5d6-7413-0410-9779-e7cbd77b26cf --- gtk2_ardour/export_format_dialog.cc | 25 +++++++++++++++++++++++++ gtk2_ardour/export_format_dialog.h | 8 ++++++++ 2 files changed, 33 insertions(+) (limited to 'gtk2_ardour') diff --git a/gtk2_ardour/export_format_dialog.cc b/gtk2_ardour/export_format_dialog.cc index 1a8ecf8ffa..68c3f3c41f 100644 --- a/gtk2_ardour/export_format_dialog.cc +++ b/gtk2_ardour/export_format_dialog.cc @@ -64,6 +64,9 @@ ExportFormatDialog::ExportFormatDialog (FormatPtr format, bool new_dialog) : sample_format_label (_("Sample Format"), Gtk::ALIGN_LEFT), dither_label (_("Dithering"), Gtk::ALIGN_LEFT), + with_cue (_("Create CUE file for disk-at-once CD/DVD creation")), + with_toc (_("Create TOC file for disk-at-once CD/DVD creation")), + tag_checkbox (_("Tag file with session's metadata")) { @@ -73,6 +76,7 @@ ExportFormatDialog::ExportFormatDialog (FormatPtr format, bool new_dialog) : get_vbox()->pack_start (silence_table, false, false, 6); get_vbox()->pack_start (format_table, false, false, 6); get_vbox()->pack_start (encoding_options_vbox, false, false, 0); + get_vbox()->pack_start (cue_toc_vbox, false, false, 0); /* Name, new and remove */ @@ -129,6 +133,12 @@ ExportFormatDialog::ExportFormatDialog (FormatPtr format, bool new_dialog) : close_button->signal_clicked().connect (sigc::mem_fun (*this, &ExportFormatDialog::end_dialog)); manager.CompleteChanged.connect (*this, invalidator (*this), ui_bind (&Gtk::Button::set_sensitive, close_button, _1), gui_context()); + with_cue.signal_toggled().connect (sigc::mem_fun (*this, &ExportFormatDialog::update_with_cue)); + with_toc.signal_toggled().connect (sigc::mem_fun (*this, &ExportFormatDialog::update_with_toc)); + + cue_toc_vbox.pack_start (with_cue, false, false); + cue_toc_vbox.pack_start (with_toc, false, false); + /* Load state before hooking up the rest of the signals */ load_state (format); @@ -234,6 +244,9 @@ ExportFormatDialog::load_state (FormatPtr spec) silence_end = spec->silence_end_time(); silence_end_checkbox.set_active (spec->silence_end_time().not_zero()); + with_cue.set_active (spec->with_cue()); + with_toc.set_active (spec->with_toc()); + for (Gtk::ListStore::Children::iterator it = src_quality_list->children().begin(); it != src_quality_list->children().end(); ++it) { if (it->get_value (src_quality_cols.id) == spec->src_quality()) { src_quality_combo.set_active (it); @@ -685,6 +698,18 @@ ExportFormatDialog::change_compatibility (bool compatibility, boost::weak_ptr } } +void +ExportFormatDialog::update_with_cue () +{ + manager.select_with_cue (with_cue.get_active()); +} + +void +ExportFormatDialog::update_with_toc () +{ + manager.select_with_toc (with_toc.get_active()); +} + void ExportFormatDialog::update_name () { diff --git a/gtk2_ardour/export_format_dialog.h b/gtk2_ardour/export_format_dialog.h index 0371b77544..9e395da01d 100644 --- a/gtk2_ardour/export_format_dialog.h +++ b/gtk2_ardour/export_format_dialog.h @@ -297,6 +297,14 @@ class ExportFormatDialog : public ArdourDialog, public PBD::ScopedConnectionList Gtk::Label sample_format_label; Gtk::Label dither_label; + Gtk::CheckButton with_cue; + Gtk::CheckButton with_toc; + + Gtk::VBox cue_toc_vbox; + + void update_with_toc (); + void update_with_cue (); + Gtk::TreeView sample_format_view; Gtk::TreeView dither_type_view; -- cgit v1.2.3