diff options
author | Sakari Bergen <sakari.bergen@beatwaves.net> | 2011-06-11 14:14:24 +0000 |
---|---|---|
committer | Sakari Bergen <sakari.bergen@beatwaves.net> | 2011-06-11 14:14:24 +0000 |
commit | 7468fdb9ca9892cec9b298690bf0edf3655d6453 (patch) | |
tree | abff397fae4e6f8c0f51a7ae71c097b6f0ad2271 /libs/ardour/ardour/export_filename.h | |
parent | 47e2b9db77ff88b0b15f942e751e56322a2887e6 (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 'libs/ardour/ardour/export_filename.h')
-rw-r--r-- | libs/ardour/ardour/export_filename.h | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/libs/ardour/ardour/export_filename.h b/libs/ardour/ardour/export_filename.h index d046b9a501..b5f0bde234 100644 --- a/libs/ardour/ardour/export_filename.h +++ b/libs/ardour/ardour/export_filename.h @@ -22,24 +22,19 @@ #define __ardour_export_filename_h__ #include <boost/shared_ptr.hpp> + #include <string> + +#include <ardour/export_pointers.h> + #include "pbd/statefuldestructible.h" namespace ARDOUR { class Session; -class ExportTimespan; -class ExportChannelConfiguration; -class ExportFormatSpecification; class ExportFilename { - private: - - typedef boost::shared_ptr<ExportTimespan> TimespanPtr; - typedef boost::shared_ptr<ExportChannelConfiguration> ChannelConfigPtr; - typedef boost::shared_ptr<ExportFormatSpecification const> FormatPtr; - public: enum DateFormat { @@ -68,7 +63,7 @@ class ExportFilename { /* data access */ - std::string get_path (FormatPtr format) const; + std::string get_path (ExportFormatSpecPtr format) const; std::string get_folder () const { return folder; } TimeFormat get_time_format () const { return time_format; } @@ -88,8 +83,8 @@ class ExportFilename { void set_channel (uint32_t value) { channel = value; } bool set_folder (std::string path); - void set_timespan (TimespanPtr ts) { timespan = ts; } - void set_channel_config (ChannelConfigPtr cc) { channel_config = cc; } + void set_timespan (ExportTimespanPtr ts) { timespan = ts; } + void set_channel_config (ExportChannelConfigPtr cc) { channel_config = cc; } /* public members */ @@ -119,8 +114,8 @@ class ExportFilename { // Due to the static allocation used in strftime(), no destructor or copy-ctor is needed for this struct tm * time_struct; - TimespanPtr timespan; - ChannelConfigPtr channel_config; + ExportTimespanPtr timespan; + ExportChannelConfigPtr channel_config; /* Serialization helpers */ |