[Bf-blender-cvs] [75321a3d24d] blender2.8: Outliner: move filter menu to the left in header.
Brecht Van Lommel
noreply at git.blender.org
Thu May 17 14:30:49 CEST 2018
Commit: 75321a3d24d87ea3f333c55ee3880d7b3972c8eb
Author: Brecht Van Lommel
Date: Thu May 17 12:27:22 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB75321a3d24d87ea3f333c55ee3880d7b3972c8eb
Outliner: move filter menu to the left in header.
===================================================================
M release/scripts/startup/bl_ui/space_outliner.py
===================================================================
diff --git a/release/scripts/startup/bl_ui/space_outliner.py b/release/scripts/startup/bl_ui/space_outliner.py
index de5c5a408d5..328e0a2267b 100644
--- a/release/scripts/startup/bl_ui/space_outliner.py
+++ b/release/scripts/startup/bl_ui/space_outliner.py
@@ -31,13 +31,20 @@ class OUTLINER_HT_header(Header):
display_mode = space.display_mode
scene = context.scene
ks = context.scene.keying_sets.active
- support_filters = display_mode in {'COLLECTIONS', 'VIEW_LAYER'}
row = layout.row(align=True)
row.template_header()
layout.prop(space, "display_mode", text="")
+ row = layout.row()
+ if display_mode == 'COLLECTIONS':
+ row.popover(space_type='OUTLINER',
+ region_type='HEADER',
+ panel_type="OUTLINER_PT_filter",
+ text="",
+ icon='FILTER')
+
OUTLINER_MT_editor_menus.draw_collapsible(context, layout)
if space.display_mode == 'DATA_API':
@@ -65,14 +72,6 @@ class OUTLINER_HT_header(Header):
row.prop(space, "use_filter_complete", text="")
row.prop(space, "use_filter_case_sensitive", text="")
- row = layout.row()
- if support_filters:
- row.popover(space_type='OUTLINER',
- region_type='HEADER',
- panel_type="OUTLINER_PT_filter",
- text="",
- icon='FILTER')
-
class OUTLINER_MT_editor_menus(Menu):
bl_idname = "OUTLINER_MT_editor_menus"
More information about the Bf-blender-cvs
mailing list