summaryrefslogtreecommitdiff
path: root/libs/ardour/location_importer.cc
diff options
context:
space:
mode:
authorSakari Bergen <sakari.bergen@beatwaves.net>2008-11-26 17:13:50 +0000
committerSakari Bergen <sakari.bergen@beatwaves.net>2008-11-26 17:13:50 +0000
commit38382b792113cbf23881c1dca64e16c2d0207d45 (patch)
tree5fb1185a6f21ecc769a4c229fc0f6b7415eabaf5 /libs/ardour/location_importer.cc
parent95a86871c028ab7f0ae16608adb9b86495678d50 (diff)
More work on track import and some cleaning up of ElementImporter interface
git-svn-id: svn://localhost/ardour2/branches/3.0@4265 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/location_importer.cc')
-rw-r--r--libs/ardour/location_importer.cc16
1 files changed, 6 insertions, 10 deletions
diff --git a/libs/ardour/location_importer.cc b/libs/ardour/location_importer.cc
index 31f19ef164..f321c1d2cb 100644
--- a/libs/ardour/location_importer.cc
+++ b/libs/ardour/location_importer.cc
@@ -95,7 +95,7 @@ LocationImporter::LocationImporter (XMLTree const & source, Session & session, L
LocationImporter::~LocationImporter ()
{
- if (!queued && location) {
+ if (!queued() && location) {
delete location;
}
}
@@ -129,7 +129,7 @@ LocationImporter::get_info () const
}
bool
-LocationImporter::prepare_move ()
+LocationImporter::_prepare_move ()
{
try {
Location const original (xml_location);
@@ -171,14 +171,13 @@ LocationImporter::prepare_move ()
}
location->set_name (name);
- queued = true;
+
return true;
}
void
-LocationImporter::cancel_move ()
-{
- queued = false;
+LocationImporter::_cancel_move ()
+{
if (location) {
delete location;
location = 0;
@@ -186,10 +185,7 @@ LocationImporter::cancel_move ()
}
void
-LocationImporter::move ()
+LocationImporter::_move ()
{
- if (!queued) {
- return;
- }
session.locations()->add (location);
}