1210:0b3b35f560f2 | 1211:83b8ed708909 |
---|---|
190 return path.mid (lastpos + 1); | 190 return path.mid (lastpos + 1); |
191 | 191 |
192 return path; | 192 return path; |
193 } | 193 } |
194 | 194 |
195 QString DocumentManager::findDocumentPath (QString relativePath) | |
196 { | |
197 return m_libraries.find(relativePath); | |
198 } | |
199 | |
200 void DocumentManager::loadFileContents(QIODevice* input, Model& model, int* numWarnings, bool* ok) | 195 void DocumentManager::loadFileContents(QIODevice* input, Model& model, int* numWarnings, bool* ok) |
201 { | 196 { |
202 if (numWarnings) | 197 if (numWarnings) |
203 *numWarnings = 0; | 198 *numWarnings = 0; |
204 | 199 |
233 QString fullpath; | 228 QString fullpath; |
234 | 229 |
235 if (search) | 230 if (search) |
236 { | 231 { |
237 print ("Opening %1...\n", path.toLower()); | 232 print ("Opening %1...\n", path.toLower()); |
238 fullpath = findDocumentPath(path.toLower()); | 233 fullpath = m_libraries.find(path.toLower()); |
239 | 234 |
240 if (fullpath.isEmpty()) | 235 if (fullpath.isEmpty()) |
241 return nullptr; | 236 return nullptr; |
242 } | 237 } |
243 else | 238 else |