summaryrefslogtreecommitdiff
path: root/gtk2_ardour
diff options
context:
space:
mode:
authorSakari Bergen <sakari.bergen@beatwaves.net>2011-06-11 14:14:24 +0000
committerSakari Bergen <sakari.bergen@beatwaves.net>2011-06-11 14:14:24 +0000
commit7468fdb9ca9892cec9b298690bf0edf3655d6453 (patch)
treeabff397fae4e6f8c0f51a7ae71c097b6f0ad2271 /gtk2_ardour
parent47e2b9db77ff88b0b15f942e751e56322a2887e6 (diff)
Typedef all globally used export smart pointer types in one file.
Some of them need to be ordered in STL containers, and thus need a special comparable wrapper for boost::shared_ptr, defined in comparable_shared_ptr.h. This also alleviates the typedef hell present earlier in some export classes :) Making the timespan pointer comparable should fix bug #4093 git-svn-id: svn://localhost/ardour2/branches/3.0@9702 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour')
-rw-r--r--gtk2_ardour/export_format_dialog.cc8
-rw-r--r--gtk2_ardour/export_format_dialog.h16
-rw-r--r--gtk2_ardour/export_preset_selector.h2
-rw-r--r--gtk2_ardour/export_timespan_selector.cc2
-rw-r--r--gtk2_ardour/export_timespan_selector.h3
5 files changed, 15 insertions, 16 deletions
diff --git a/gtk2_ardour/export_format_dialog.cc b/gtk2_ardour/export_format_dialog.cc
index d719fcecb3..c8e139acce 100644
--- a/gtk2_ardour/export_format_dialog.cc
+++ b/gtk2_ardour/export_format_dialog.cc
@@ -493,7 +493,7 @@ ExportFormatDialog::update_compatibility_selection (std::string const & path)
{
Gtk::TreeModel::iterator iter = compatibility_view.get_model ()->get_iter (path);
- ExportFormatManager::CompatPtr ptr = iter->get_value (compatibility_cols.ptr);
+ ExportFormatCompatibilityPtr ptr = iter->get_value (compatibility_cols.ptr);
bool state = iter->get_value (compatibility_cols.selected);
iter->set_value (compatibility_cols.selected, state);
@@ -553,7 +553,7 @@ ExportFormatDialog::change_compatibility_selection (bool select, WeakCompatPtr c
{
++applying_changes_from_engine;
- ExportFormatManager::CompatPtr ptr = compat.lock();
+ ExportFormatCompatibilityPtr ptr = compat.lock();
for (Gtk::ListStore::Children::iterator it = compatibility_list->children().begin(); it != compatibility_list->children().end(); ++it) {
if (it->get_value (compatibility_cols.ptr) == ptr) {
@@ -576,7 +576,7 @@ ExportFormatDialog::change_format_selection (bool select, WeakFormatPtr format)
{
change_selection<ExportFormat, FormatCols> (select, format, format_list, format_view, format_cols);
- ExportFormatManager::FormatPtr ptr = format.lock();
+ ExportFormatPtr ptr = format.lock();
if (select && ptr) {
change_encoding_options (ptr);
@@ -798,7 +798,7 @@ ExportFormatDialog::update_tagging_selection ()
}
void
-ExportFormatDialog::change_encoding_options (ExportFormatManager::FormatPtr ptr)
+ExportFormatDialog::change_encoding_options (ExportFormatPtr ptr)
{
empty_encoding_option_table ();
diff --git a/gtk2_ardour/export_format_dialog.h b/gtk2_ardour/export_format_dialog.h
index f22e342589..0371b77544 100644
--- a/gtk2_ardour/export_format_dialog.h
+++ b/gtk2_ardour/export_format_dialog.h
@@ -37,9 +37,9 @@
class ExportFormatDialog : public ArdourDialog, public PBD::ScopedConnectionList {
private:
- typedef ARDOUR::ExportFormatManager::WeakCompatPtr WeakCompatPtr;
+ typedef ARDOUR::WeakExportFormatCompatibilityPtr WeakCompatPtr;
+ typedef ARDOUR::WeakExportFormatPtr WeakFormatPtr;
typedef ARDOUR::ExportFormatManager::WeakQualityPtr WeakQualityPtr;
- typedef ARDOUR::ExportFormatManager::WeakFormatPtr WeakFormatPtr;
typedef ARDOUR::ExportFormatManager::WeakSampleRatePtr WeakSampleRatePtr;
typedef ARDOUR::ExportFormatManager::WeakSampleFormatPtr WeakSampleFormatPtr;
typedef ARDOUR::ExportFormatManager::WeakDitherTypePtr WeakDitherTypePtr;
@@ -131,7 +131,7 @@ class ExportFormatDialog : public ArdourDialog, public PBD::ScopedConnectionList
/*** Encoding options */
- void change_encoding_options (ARDOUR::ExportFormatManager::FormatPtr ptr);
+ void change_encoding_options (ARDOUR::ExportFormatPtr ptr);
void empty_encoding_option_table ();
void remove_widget (Gtk::Widget & to_remove, Gtk::Container * remove_from);
@@ -177,8 +177,8 @@ class ExportFormatDialog : public ArdourDialog, public PBD::ScopedConnectionList
struct CompatibilityCols : public Gtk::TreeModelColumnRecord
{
public:
- Gtk::TreeModelColumn<ARDOUR::ExportFormatManager::CompatPtr> ptr;
- Gtk::TreeModelColumn<bool> selected;
+ Gtk::TreeModelColumn<ARDOUR::ExportFormatCompatibilityPtr> ptr;
+ Gtk::TreeModelColumn<bool> selected;
Gtk::TreeModelColumn<std::string> label;
CompatibilityCols () { add(ptr); add(selected); add(label); }
@@ -205,9 +205,9 @@ class ExportFormatDialog : public ArdourDialog, public PBD::ScopedConnectionList
struct FormatCols : public Gtk::TreeModelColumnRecord
{
public:
- Gtk::TreeModelColumn<ARDOUR::ExportFormatManager::FormatPtr> ptr;
- Gtk::TreeModelColumn<std::string> color;
- Gtk::TreeModelColumn<std::string> label;
+ Gtk::TreeModelColumn<ARDOUR::ExportFormatPtr> ptr;
+ Gtk::TreeModelColumn<std::string> color;
+ Gtk::TreeModelColumn<std::string> label;
FormatCols () { add(ptr); add(color); add(label); }
};
diff --git a/gtk2_ardour/export_preset_selector.h b/gtk2_ardour/export_preset_selector.h
index 73211cb523..a57fc83aad 100644
--- a/gtk2_ardour/export_preset_selector.h
+++ b/gtk2_ardour/export_preset_selector.h
@@ -40,7 +40,7 @@ class ExportPresetSelector : public Gtk::HBox
private:
typedef boost::shared_ptr<ARDOUR::ExportProfileManager> ManagerPtr;
- typedef ARDOUR::ExportProfileManager::PresetPtr PresetPtr;
+ typedef ARDOUR::ExportPresetPtr PresetPtr;
typedef ARDOUR::ExportProfileManager::PresetList PresetList;
ManagerPtr profile_manager;
diff --git a/gtk2_ardour/export_timespan_selector.cc b/gtk2_ardour/export_timespan_selector.cc
index bf89f8c9ee..78e92a22a6 100644
--- a/gtk2_ardour/export_timespan_selector.cc
+++ b/gtk2_ardour/export_timespan_selector.cc
@@ -102,7 +102,7 @@ ExportTimespanSelector::~ExportTimespanSelector ()
void
ExportTimespanSelector::add_range_to_selection (ARDOUR::Location const * loc)
{
- TimespanPtr span = _session->get_export_handler()->add_timespan();
+ ExportTimespanPtr span = _session->get_export_handler()->add_timespan();
std::string id;
if (loc == state->session_range.get()) {
diff --git a/gtk2_ardour/export_timespan_selector.h b/gtk2_ardour/export_timespan_selector.h
index 688971554d..8b06b2ee8d 100644
--- a/gtk2_ardour/export_timespan_selector.h
+++ b/gtk2_ardour/export_timespan_selector.h
@@ -49,8 +49,7 @@ class ExportTimespanSelector : public Gtk::VBox, public ARDOUR::SessionHandlePtr
typedef boost::shared_ptr<ARDOUR::ExportHandler> HandlerPtr;
typedef boost::shared_ptr<ARDOUR::ExportProfileManager> ProfileManagerPtr;
- typedef boost::shared_ptr<ARDOUR::ExportTimespan> TimespanPtr;
- typedef std::list<TimespanPtr> TimespanList;
+ typedef std::list<ARDOUR::ExportTimespanPtr> TimespanList;
typedef boost::shared_ptr<TimespanList> TimespanListPtr;
typedef ARDOUR::ExportProfileManager::TimespanStatePtr TimespanStatePtr;