comparison data/fileio/FileSource.cpp @ 616:3a61a4df6d53

* 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 87b81f959706
children a4faa1840384
comparison
equal deleted inserted replaced
615:521438145bd7 616:3a61a4df6d53
97 init(); 97 init();
98 98
99 if (!isRemote() && 99 if (!isRemote() &&
100 !isAvailable()) { 100 !isAvailable()) {
101 #ifdef DEBUG_FILE_SOURCE 101 #ifdef DEBUG_FILE_SOURCE
102 std::cerr << "FileSource::FileSource: Failed to open local file with URL \"" << m_url.toString().toStdString() << "; trying again with tolerant encoding" << std::endl; 102 std::cerr << "FileSource::FileSource: Failed to open local file with URL \"" << m_url.toString().toStdString() << "; trying again assuming filename was encoded" << std::endl;
103 #endif 103 #endif
104 m_url = QUrl(fileOrUrl, QUrl::TolerantMode); 104 m_url = QUrl::fromEncoded(fileOrUrl.toAscii());
105 init(); 105 init();
106 } 106 }
107 107
108 if (isRemote() && 108 if (isRemote() &&
109 (fileOrUrl.contains('%') || 109 (fileOrUrl.contains('%') ||