diff options
author | Julian Eisel <eiseljulian@gmail.com> | 2019-09-04 17:21:42 +0300 |
---|---|---|
committer | Julian Eisel <eiseljulian@gmail.com> | 2019-09-04 17:30:09 +0300 |
commit | 45d4c925799e94c6d442a9a9066af2d3305724e1 (patch) | |
tree | b3d5a785539527510a5a2f110e36a485213ac35b /release/scripts/startup | |
parent | 640c45dc3a50ebc4c584bb7ca48d5075e0104bb4 (diff) |
Move file execute region back to C, fixing bugs
We moved this to Python too quickly, causing the following regressions:
* No auto completion for file names
* Additional handling not applied on changes, like automatic extension
appending (see file_filename_enter_handle)
* Red highlight missing when the file name already exists
Note that earlier (before the file browser redesign), this didn't use
the panel and layout code at all. So even if it's still not in Python,
at least it's integrated into regular panel management now.
OS-specific ordering of the open and cancel button is kept.
Fixes T69457.
Diffstat (limited to 'release/scripts/startup')
-rw-r--r-- | release/scripts/startup/bl_ui/space_filebrowser.py | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/release/scripts/startup/bl_ui/space_filebrowser.py b/release/scripts/startup/bl_ui/space_filebrowser.py index 7a803906369..92eae7a4de9 100644 --- a/release/scripts/startup/bl_ui/space_filebrowser.py +++ b/release/scripts/startup/bl_ui/space_filebrowser.py @@ -414,46 +414,6 @@ class FILEBROWSER_PT_directory_path(Panel): ) -class FILEBROWSER_PT_file_operation(Panel): - bl_space_type = 'FILE_BROWSER' - bl_region_type = 'EXECUTE' - bl_label = "Execute File Operation" - bl_options = {'HIDE_HEADER'} - - @classmethod - def poll(cls, context): - return context.space_data.active_operator - - def draw(self, context): - import sys - - layout = self.layout - space = context.space_data - params = space.params - - layout.scale_x = 1.3 - layout.scale_y = 1.3 - - row = layout.row() - sub = row.row() - sub.prop(params, "filename", text="") - sub = row.row() - sub.ui_units_x = 5 - - # subsub = sub.row(align=True) - # subsub.operator("file.filenum", text="", icon='ADD').increment = 1 - # subsub.operator("file.filenum", text="", icon='REMOVE').increment = -1 - - # organize buttons according to the OS standard - if sys.platform[:3] != "win": - sub.operator("FILE_OT_cancel", text="Cancel") - subsub = sub.row() - subsub.active_default = True - subsub.operator("FILE_OT_execute", text=params.title) - if sys.platform[:3] == "win": - sub.operator("FILE_OT_cancel", text="Cancel") - - class FILEBROWSER_MT_view(Menu): bl_label = "View" @@ -523,7 +483,6 @@ classes = ( FILEBROWSER_PT_bookmarks_recents, FILEBROWSER_PT_advanced_filter, FILEBROWSER_PT_directory_path, - FILEBROWSER_PT_file_operation, FILEBROWSER_PT_options_toggle, FILEBROWSER_MT_view, FILEBROWSER_MT_context_menu, |