[Bf-blender-cvs] [5dcabc4d579] master: Fix T65770: File Browser missing "Sidebar" in View menu

Campbell Barton noreply at git.blender.org
Thu Jun 20 06:51:49 CEST 2019


Commit: 5dcabc4d5795522c145da5116d8aeac2db7ac8a6
Author: Campbell Barton
Date:   Thu Jun 20 14:49:55 2019 +1000
Branches: master
https://developer.blender.org/rB5dcabc4d5795522c145da5116d8aeac2db7ac8a6

Fix T65770: File Browser missing "Sidebar" in View menu

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

M	release/scripts/startup/bl_ui/space_filebrowser.py
M	source/blender/makesrna/intern/rna_space.c

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

diff --git a/release/scripts/startup/bl_ui/space_filebrowser.py b/release/scripts/startup/bl_ui/space_filebrowser.py
index eb9964bb180..b939586ff81 100644
--- a/release/scripts/startup/bl_ui/space_filebrowser.py
+++ b/release/scripts/startup/bl_ui/space_filebrowser.py
@@ -250,6 +250,11 @@ class FILEBROWSER_MT_view(Menu):
         st = context.space_data
         params = st.params
 
+        layout.prop(st, "show_region_toolbar")
+        layout.prop(st, "show_region_ui", text="File Path")
+
+        layout.separator()
+
         layout.prop_menu_enum(params, "display_size")
         layout.prop_menu_enum(params, "recursion_level")
 
diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c
index 561cbb2ec3a..0c7797326db 100644
--- a/source/blender/makesrna/intern/rna_space.c
+++ b/source/blender/makesrna/intern/rna_space.c
@@ -5489,6 +5489,8 @@ static void rna_def_space_filebrowser(BlenderRNA *brna)
   RNA_def_struct_sdna(srna, "SpaceFile");
   RNA_def_struct_ui_text(srna, "Space File Browser", "File browser space data");
 
+  rna_def_space_generic_show_region_toggles(srna, (1 << RGN_TYPE_TOOLS) | (1 << RGN_TYPE_UI));
+
   prop = RNA_def_property(srna, "params", PROP_POINTER, PROP_NONE);
   RNA_def_property_pointer_sdna(prop, NULL, "params");
   RNA_def_property_ui_text(



More information about the Bf-blender-cvs mailing list