globally remove all trailing whitespace from ardour code base.
[ardour.git] / libs / ardour / ardour / session.h
index 79eb2162da7a50d9a2ee102b76019beceb1c0a7a..2bc992bb108538dc64b312196ebea422feccb1e8 100644 (file)
@@ -191,6 +191,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
        bool reconnection_in_progress() const { return _reconnecting_routes_in_progress; }
        bool deletion_in_progress() const { return _state_of_the_state & Deletion; }
        bool routes_deletion_in_progress() const { return _route_deletion_in_progress; }
+       bool peaks_cleanup_in_progres() const { return _state_of_the_state & PeakCleanup; }
 
        PBD::Signal0<void> DirtyChanged;
 
@@ -480,10 +481,10 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
         *
         * Argument is the snapshot name to use when saving.
         */
-       PBD::Signal1<void,std::string> SaveSessionRequested; 
+       PBD::Signal1<void,std::string> SaveSessionRequested;
 
        /* emitted during a session save to allow other entities to add state, via
-        * extra XML, to the session state 
+        * extra XML, to the session state
         */
        PBD::Signal0<void> SessionSaveUnderway;
 
@@ -505,7 +506,8 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
                Deletion = 0x4,
                InitialConnecting = 0x8,
                Loading = 0x10,
-               InCleanup = 0x20
+               InCleanup = 0x20,
+               PeakCleanup = 0x40
        };
 
        StateOfTheState state_of_the_state() const { return _state_of_the_state; }
@@ -566,7 +568,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
        std::list<boost::shared_ptr<MidiTrack> > new_midi_track (
                const ChanCount& input, const ChanCount& output,
                boost::shared_ptr<PluginInfo> instrument = boost::shared_ptr<PluginInfo>(),
-               TrackMode mode = Normal, 
+               TrackMode mode = Normal,
                RouteGroup* route_group = 0, uint32_t how_many = 1, std::string name_template = ""
                );
 
@@ -661,7 +663,9 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
        void add_source (boost::shared_ptr<Source>);
        void remove_source (boost::weak_ptr<Source>);
 
-       void  cleanup_regions();
+       void cleanup_regions();
+       bool can_cleanup_peakfiles () const;
+       int  cleanup_peakfiles ();
        int  cleanup_sources (CleanupReport&);
        int  cleanup_trash_sources (CleanupReport&);
 
@@ -1026,7 +1030,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
        boost::shared_ptr<MidiPort> midi_clock_input_port () const;
        boost::shared_ptr<MidiPort> mtc_output_port () const;
        boost::shared_ptr<MidiPort> mtc_input_port () const;
-    
+
        MIDI::MachineControl& mmc() { return *_mmc; }
 
        void reconnect_midi_scene_ports (bool);
@@ -1243,6 +1247,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
        gint            _suspend_save; /* atomic */
        volatile bool   _save_queued;
        Glib::Threads::Mutex save_state_lock;
+       Glib::Threads::Mutex peak_cleanup_lock;
 
        int      load_options (const XMLNode&);
        int      load_state (std::string snapshot_name);
@@ -1296,7 +1301,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
        void consolidate_skips (Location*);
        void sync_locations_to_skips ();
        void _sync_locations_to_skips ();
-    
+
        PBD::ScopedConnectionList skip_update_connections;
        bool _ignore_skips_updates;
 
@@ -1461,7 +1466,7 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
        void flush_all_inserts ();
        int  micro_locate (framecnt_t distance);
        void locate (framepos_t, bool with_roll, bool with_flush, bool with_loop=false, bool force=false, bool with_mmc=true);
-       void start_locate (framepos_t, bool with_roll, bool with_flush, bool with_loop=false, bool force=false);
+       void start_locate (framepos_t, bool with_roll, bool with_flush, bool for_loop_enabled=false, bool force=false);
        void force_locate (framepos_t frame, bool with_roll = false);
        void set_track_speed (Track *, double speed);
        void set_transport_speed (double speed, framepos_t destination_frame, bool abort = false, bool clear_state = false, bool as_default = false);