summaryrefslogtreecommitdiff
path: root/libs/ardour/file_source.cc
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2009-02-20 00:30:42 +0000
committerDavid Robillard <d@drobilla.net>2009-02-20 00:30:42 +0000
commitc9582da23371bfd40f3087f5a9112d081ef012da (patch)
treed039fc76d262918d0335941ad5933bf7ccebfd05 /libs/ardour/file_source.cc
parentbed0d89337b0775e669439ef4e0759feb7ddc74e (diff)
Make source length a dynamic thing.
Update MIDI region length (actually and visually) when position changes. git-svn-id: svn://localhost/ardour2/branches/3.0@4644 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/file_source.cc')
-rw-r--r--libs/ardour/file_source.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/libs/ardour/file_source.cc b/libs/ardour/file_source.cc
index ed9c80338a..649fc6156b 100644
--- a/libs/ardour/file_source.cc
+++ b/libs/ardour/file_source.cc
@@ -77,13 +77,12 @@ FileSource::removable () const
{
return (_flags & Removable)
&& ( (_flags & RemoveAtDestroy)
- || ((_flags & RemovableIfEmpty) && length() == 0));
+ || ((_flags & RemovableIfEmpty) && length(timeline_position()) == 0));
}
int
FileSource::init (const ustring& pathstr, bool must_exist)
{
- _length = 0;
_timeline_position = 0;
if (!find (_type, pathstr, must_exist, _file_is_new, _channel)) {