Mercurial > hg > svapp
comparison framework/MainWindowBase.cpp @ 186:f694ee2567fe
* RDF importer: Features that are on different timeline URIs should go
into separate models (_not_ just on separate signal URIs as there may
not be any meaningful signal URIs)
* FileSource: if a file is not found, try again assuming its name is
encoded (not just in tolerant mode)
author | Chris Cannam |
---|---|
date | Thu, 15 Oct 2009 10:50:43 +0000 |
parents | 9f49d0f1bd20 |
children | 5a40619c72d8 |
comparison
equal
deleted
inserted
replaced
185:9f49d0f1bd20 | 186:f694ee2567fe |
---|---|
1618 MainWindowBase::FileOpenStatus | 1618 MainWindowBase::FileOpenStatus |
1619 MainWindowBase::openLayersFromRDF(FileSource source) | 1619 MainWindowBase::openLayersFromRDF(FileSource source) |
1620 { | 1620 { |
1621 size_t rate = 0; | 1621 size_t rate = 0; |
1622 | 1622 |
1623 std::cerr << "MainWindowBase::openLayersFromRDF" << std::endl; | |
1624 | |
1623 ProgressDialog dialog(tr("Importing from RDF..."), true, 2000, this); | 1625 ProgressDialog dialog(tr("Importing from RDF..."), true, 2000, this); |
1624 connect(&dialog, SIGNAL(showing()), this, SIGNAL(hideSplash())); | 1626 connect(&dialog, SIGNAL(showing()), this, SIGNAL(hideSplash())); |
1625 | 1627 |
1626 if (getMainModel()) { | 1628 if (getMainModel()) { |
1627 rate = getMainModel()->getSampleRate(); | 1629 rate = getMainModel()->getSampleRate(); |
1645 std::vector<Model *> models = importer.getDataModels(&dialog); | 1647 std::vector<Model *> models = importer.getDataModels(&dialog); |
1646 | 1648 |
1647 dialog.setMessage(tr("Importing from RDF...")); | 1649 dialog.setMessage(tr("Importing from RDF...")); |
1648 | 1650 |
1649 if (models.empty()) { | 1651 if (models.empty()) { |
1652 QMessageBox::critical | |
1653 (this, tr("Failed to import RDF"), | |
1654 tr("<b>Failed to import RDF</b><p>No suitable data models found for import from RDF document at \"%1\"</p>").arg(source.getLocation())); | |
1650 return FileOpenFailed; | 1655 return FileOpenFailed; |
1651 } | 1656 } |
1652 | 1657 |
1653 emit activity(tr("Import RDF document \"%1\"").arg(source.getLocation())); | 1658 emit activity(tr("Import RDF document \"%1\"").arg(source.getLocation())); |
1654 | 1659 |