Mercurial > hg > sonic-visualiser
comparison main/MainWindow.cpp @ 522:d6ddc2c2a6ed
Fix failure to either export a file or explain why, when exporting an unsupported layer type to rdf
author | Chris Cannam |
---|---|
date | Tue, 11 Dec 2012 13:07:59 +0000 |
parents | 581c72fb14a4 |
children | a740e96d7fec |
comparison
equal
deleted
inserted
replaced
521:cc4ff6fde597 | 522:d6ddc2c2a6ed |
---|---|
2592 } | 2592 } |
2593 } | 2593 } |
2594 | 2594 |
2595 } else if (suffix == "ttl" || suffix == "n3") { | 2595 } else if (suffix == "ttl" || suffix == "n3") { |
2596 | 2596 |
2597 RDFExporter exporter(path, model); | 2597 if (!RDFExporter::canExportModel(model)) { |
2598 exporter.write(); | 2598 error = tr("Sorry, cannot export this layer type to RDF (supported types are: region, note, text, time instants, time values)"); |
2599 if (!exporter.isOK()) { | 2599 } else { |
2600 error = exporter.getError(); | 2600 RDFExporter exporter(path, model); |
2601 exporter.write(); | |
2602 if (!exporter.isOK()) { | |
2603 error = exporter.getError(); | |
2604 } | |
2601 } | 2605 } |
2602 | 2606 |
2603 } else { | 2607 } else { |
2604 | 2608 |
2605 CSVFileWriter writer(path, model, | 2609 CSVFileWriter writer(path, model, |