Fix #140942: FBX importer fails when using file browser recursive option
The `files` property, provided by the blender file browser, contain paths relative to the `directory` property. Use that instead of using the file's parent directory. Pull Request: https://projects.blender.org/blender/blender/pulls/141575
This commit is contained in:
committed by
Jesse Yurkovich
parent
0ce5738415
commit
2cf0c63461
@@ -215,9 +215,8 @@ class ImportFBX(bpy.types.Operator, ImportHelper):
|
||||
|
||||
if self.files:
|
||||
ret = {'CANCELLED'}
|
||||
dirname = os.path.dirname(self.filepath)
|
||||
for file in self.files:
|
||||
path = os.path.join(dirname, file.name)
|
||||
path = os.path.join(self.directory, file.name)
|
||||
if import_fbx.load(self, context, filepath=path, **keywords) == {'FINISHED'}:
|
||||
ret = {'FINISHED'}
|
||||
return ret
|
||||
|
||||
Reference in New Issue
Block a user