mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-22 14:55:36 +08:00
Check that X-Plane OBJ8 file exists
This commit is contained in:
committed by
Mat Sutcliffe
parent
108f773e8a
commit
e8b14c435f
@@ -548,6 +548,12 @@ namespace BlackMisc
|
|||||||
dirNames.removeLast();
|
dirNames.removeLast();
|
||||||
|
|
||||||
QFileInfo fileInfo(fullPath);
|
QFileInfo fileInfo(fullPath);
|
||||||
|
if (! fileInfo.exists())
|
||||||
|
{
|
||||||
|
const CStatusMessage m = CStatusMessage(this).error(u"XPlane object '%1' does not exist.") << fullPath;
|
||||||
|
m_loadingMessages.push_back(m);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
package.planes.back().dirNames = dirNames;
|
package.planes.back().dirNames = dirNames;
|
||||||
package.planes.back().objectName = fileInfo.completeBaseName();
|
package.planes.back().objectName = fileInfo.completeBaseName();
|
||||||
package.planes.back().filePath = fullPath;
|
package.planes.back().filePath = fullPath;
|
||||||
|
|||||||
Reference in New Issue
Block a user