summaryrefslogtreecommitdiff
path: root/libs/ardour/file_source.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2012-07-16 14:48:07 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2012-07-16 14:48:07 +0000
commit539b94490f7ab660f24b3de80df5514f61d481b0 (patch)
tree76658aecc60eb87dedb686e81ed8c3a69a827021 /libs/ardour/file_source.cc
parentf97da74cf7d3c2d3ae580473fa4639b0b259bf5b (diff)
do NOT mark imported MIDI files as un-writable - all MIDI files are subject to rewriting at any time
git-svn-id: svn://localhost/ardour2/branches/3.0@13046 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/file_source.cc')
-rw-r--r--libs/ardour/file_source.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/libs/ardour/file_source.cc b/libs/ardour/file_source.cc
index 2f7ad2caa8..3017615948 100644
--- a/libs/ardour/file_source.cc
+++ b/libs/ardour/file_source.cc
@@ -555,6 +555,15 @@ FileSource::mark_immutable ()
}
void
+FileSource::mark_immutable_except_write ()
+{
+ /* destructive sources stay writable, and their other flags don't change. */
+ if (!(_flags & Destructive)) {
+ _flags = Flag (_flags & ~(Removable|RemovableIfEmpty|RemoveAtDestroy|CanRename));
+ }
+}
+
+void
FileSource::mark_nonremovable ()
{
_flags = Flag (_flags & ~(Removable|RemovableIfEmpty|RemoveAtDestroy));