[Bf-blender-cvs] [dfd2570d28a] master: WM: define WM_OT_drop_blend_file path as a file-path, skip-save

Campbell Barton noreply at git.blender.org
Fri Aug 12 03:05:05 CEST 2022


Commit: dfd2570d28a880d73d347e52a4ff2a69cbd658b9
Author: Campbell Barton
Date:   Fri Aug 12 10:59:14 2022 +1000
Branches: master
https://developer.blender.org/rBdfd2570d28a880d73d347e52a4ff2a69cbd658b9

WM: define WM_OT_drop_blend_file path as a file-path, skip-save

File paths have special handling of non-utf8 characters, so it's
best to use the FILE_PATH sup-type for all file-paths.

===================================================================

M	release/scripts/startup/bl_operators/wm.py

===================================================================

diff --git a/release/scripts/startup/bl_operators/wm.py b/release/scripts/startup/bl_operators/wm.py
index 7e7dbbc387e..cbb5a63b754 100644
--- a/release/scripts/startup/bl_operators/wm.py
+++ b/release/scripts/startup/bl_operators/wm.py
@@ -3152,7 +3152,10 @@ class WM_OT_drop_blend_file(Operator):
     bl_label = "Handle dropped .blend file"
     bl_options = {'INTERNAL'}
 
-    filepath: StringProperty()
+    filepath: StringProperty(
+        subtype='FILE_PATH',
+        options={'SKIP_SAVE'},
+    )
 
     def invoke(self, context, _event):
         context.window_manager.popup_menu(self.draw_menu, title=bpy.path.basename(self.filepath), icon='QUESTION')



More information about the Bf-blender-cvs mailing list