major, substantive reworking of how we store GUI information (visibility, height...
[ardour.git] / libs / ardour / ardour / export_formats.h
index 3312e9abd626cbf27314a13085beb9c26f448122..0e9a93ff9656c5a5b5009645fbace3ef3f3c7511 100644 (file)
 #ifndef __ardour_export_formats_h__
 #define __ardour_export_formats_h__
 
-#include "ardour/export_format_base.h"
-#include "ardour/export_format_compatibility.h"
-
 #include <list>
 #include <boost/weak_ptr.hpp>
+
 #include "pbd/failed_constructor.h"
+#include "pbd/signals.h"
+
+#include "ardour/export_format_base.h"
+#include "ardour/export_format_compatibility.h"
 
 namespace ARDOUR
 {
@@ -84,13 +86,16 @@ class ExportFormat : public ExportFormatBase, public ExportFormatBase::Selectabl
 };
 
 /// Class to be inherited by export formats that have a selectable sample format
-class HasSampleFormat {
+class HasSampleFormat : public PBD::ScopedConnectionList {
   public:
 
        class SampleFormatState : public ExportFormatBase::SelectableCompatible {
          public:
-               SampleFormatState (ExportFormatBase::SampleFormat format, Glib::ustring name) :
-                 format (format) { set_name (name); }
+               SampleFormatState (ExportFormatBase::SampleFormat format, std::string name)
+                       : format (format)
+               {
+                       set_name (name);
+               }
 
                ExportFormatBase::SampleFormat  format;
        };
@@ -126,11 +131,11 @@ class HasSampleFormat {
 
        /* Proxies for signals from sample formats and dither types */
 
-       sigc::signal<void, bool, WeakSampleFormatPtr> SampleFormatSelectChanged;
-       sigc::signal<void, bool, WeakSampleFormatPtr> SampleFormatCompatibleChanged;
+       PBD::Signal2<void,bool, WeakSampleFormatPtr> SampleFormatSelectChanged;
+       PBD::Signal2<void,bool, WeakSampleFormatPtr> SampleFormatCompatibleChanged;
 
-       sigc::signal<void, bool, WeakDitherTypePtr> DitherTypeSelectChanged;
-       sigc::signal<void, bool, WeakDitherTypePtr> DitherTypeCompatibleChanged;
+       PBD::Signal2<void,bool, WeakDitherTypePtr> DitherTypeSelectChanged;
+       PBD::Signal2<void,bool, WeakDitherTypePtr> DitherTypeCompatibleChanged;
 
        static std::string get_sample_format_name (ExportFormatBase::SampleFormat format);
 
@@ -143,7 +148,7 @@ class HasSampleFormat {
   private:
        /* Connected to signals */
 
-       void add_dither_type (ExportFormatBase::DitherType type, Glib::ustring name);
+       void add_dither_type (ExportFormatBase::DitherType type, std::string name);
        void update_sample_format_selection (bool);
        void update_dither_type_selection (bool);
 
@@ -154,7 +159,7 @@ class HasSampleFormat {
 class ExportFormatLinear : public ExportFormat, public HasSampleFormat {
   public:
 
-       ExportFormatLinear (Glib::ustring name, FormatId format_id);
+       ExportFormatLinear (std::string name, FormatId format_id);
        ~ExportFormatLinear () {};
 
        bool set_compatibility_state (ExportFormatCompatibility const & compatibility);