#include "ardour/export_format_specification.h"
+#include "gui_thread.h"
#include "utils.h"
#include "i18n.h"
void
ExportFileNotebook::set_session_and_manager (ARDOUR::Session * s, boost::shared_ptr<ARDOUR::ExportProfileManager> manager)
{
- session = s;
+ SessionHandlePtr::set_session (s);
profile_manager = manager;
sync_with_manager ();
CriticalSelectionChanged ();
}
-Glib::ustring
+std::string
ExportFileNotebook::get_nth_format_name (uint32_t n)
{
FilePage * page;
void
ExportFileNotebook::add_file_page (ARDOUR::ExportProfileManager::FormatStatePtr format_state, ARDOUR::ExportProfileManager::FilenameStatePtr filename_state)
{
- FilePage * page = Gtk::manage (new FilePage (session, profile_manager, this, page_counter, format_state, filename_state));
+ FilePage * page = Gtk::manage (new FilePage (_session, profile_manager, this, page_counter, format_state, filename_state));
page->CriticalSelectionChanged.connect (CriticalSelectionChanged.make_slot());
insert_page (*page, page->get_tab_widget(), get_n_pages() - 1);
tab_close_button.signal_clicked().connect (sigc::bind (sigc::mem_fun (*parent, &ExportFileNotebook::remove_file_page), this));
- profile_manager->FormatListChanged.connect (sigc::mem_fun (format_selector, &ExportFormatSelector::update_format_list));
+ profile_manager->FormatListChanged.connect (format_connection, invalidator (*this), boost::bind (&ExportFormatSelector::update_format_list, &format_selector), gui_context());
format_selector.FormatEdited.connect (sigc::mem_fun (*this, &ExportFileNotebook::FilePage::save_format_to_manager));
format_selector.FormatRemoved.connect (sigc::mem_fun (*profile_manager, &ExportProfileManager::remove_format_profile));
tab_close_button.set_sensitive (value);
}
-Glib::ustring
+std::string
ExportFileNotebook::FilePage::get_format_name () const
{
if (format_state && format_state->format) {