summaryrefslogtreecommitdiff
path: root/libs/ardour/location.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2007-11-07 02:42:27 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2007-11-07 02:42:27 +0000
commit8e73c9ee80c260c58698894332f08769e9f1ac22 (patch)
treef5882e1353eecbe3e82243b19a953d205581dc93 /libs/ardour/location.cc
parent3069423106e9901ccad74624ad30756dd8338a36 (diff)
patch to prevent (mostly) CD marker being set for the start of the session
git-svn-id: svn://localhost/ardour2/trunk@2601 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/location.cc')
-rw-r--r--libs/ardour/location.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/libs/ardour/location.cc b/libs/ardour/location.cc
index bd9e7b8af5..093c6cf8fc 100644
--- a/libs/ardour/location.cc
+++ b/libs/ardour/location.cc
@@ -169,6 +169,14 @@ Location::set_hidden (bool yn, void *src)
void
Location::set_cd (bool yn, void *src)
{
+ // XXX this really needs to be session start
+ // but its not available here - leave to GUI
+
+ if (_start == 0) {
+ error << _("You cannot put a CD marker at this position") << endmsg;
+ return;
+ }
+
if (set_flag_internal (yn, IsCDMarker)) {
FlagsChanged (this, src); /* EMIT SIGNAL */
}