diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-09-23 17:44:06 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-09-23 17:44:06 +0300 |
commit | e2e567e0b43f0f354caceb6ac493a2f4a3f1e130 (patch) | |
tree | 43cf3c4b70da007e46f3850ba1be02cd47c9db3e /release | |
parent | a168c3d282083bb4c02078bbd374f5554eeddce3 (diff) |
Fix file browser new directory prompting for confirmation
This is only needed for the case where it's automatically done when entering a
file path that does not exist, not when pressing the button.
Diffstat (limited to 'release')
-rw-r--r-- | release/scripts/startup/bl_ui/space_filebrowser.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/release/scripts/startup/bl_ui/space_filebrowser.py b/release/scripts/startup/bl_ui/space_filebrowser.py index 3279271b5e8..c0d954261f6 100644 --- a/release/scripts/startup/bl_ui/space_filebrowser.py +++ b/release/scripts/startup/bl_ui/space_filebrowser.py @@ -368,7 +368,9 @@ class FILEBROWSER_PT_directory_path(Panel): subrow.operator("file.parent", text="", icon='FILE_PARENT') subrow.operator("file.refresh", text="", icon='FILE_REFRESH') - row.operator("file.directory_new", icon='NEWFOLDER', text="") + subrow = row.row() + subrow.operator_context = 'EXEC_DEFAULT' + subrow.operator("file.directory_new", icon='NEWFOLDER', text="") subrow = row.row() subrow.template_file_select_path(params) @@ -464,7 +466,9 @@ class FILEBROWSER_MT_context_menu(Menu): layout.operator("file.rename", text="Rename") # layout.operator("file.delete") - layout.operator("file.directory_new", text="New Folder") + sub = layout.row() + sub.operator_context = 'EXEC_DEFAULT' + sub.operator("file.directory_new", text="New Folder") layout.operator("file.bookmark_add", text="Add Bookmark") layout.separator() |