[9713b11] blender-v2.76-release: Fix FileBrowser: do not show 'advanced filter' panel outside of lib browsing context, it’s only used there so far.

Bastien Montagne noreply at git.blender.org
Fri Oct 9 13:32:58 CEST 2015


Commit: 9713b116447bb12dd702f1ee9f4aa1eacf0325d2
Author: Bastien Montagne
Date:   Tue Oct 6 20:17:40 2015 +0200
Branches: blender-v2.76-release
https://developer.blender.org/rB9713b116447bb12dd702f1ee9f4aa1eacf0325d2

Fix FileBrowser: do not show 'advanced filter' panel outside of lib browsing context,
it’s only used there so far.

Reported by Thomas Beck (plasmasolutions) over IRC, thanks.

Safe enough for 2.76.

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

M	release/scripts/startup/bl_ui/space_filebrowser.py

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

diff --git a/release/scripts/startup/bl_ui/space_filebrowser.py b/release/scripts/startup/bl_ui/space_filebrowser.py
index ca69520..f6f86c0 100644
--- a/release/scripts/startup/bl_ui/space_filebrowser.py
+++ b/release/scripts/startup/bl_ui/space_filebrowser.py
@@ -229,6 +229,11 @@ class FILEBROWSER_PT_advanced_filter(Panel):
     bl_category = "Filter"
     bl_label = "Advanced Filter"
 
+    @classmethod
+    def poll(cls, context):
+        # only useful in append/link (library) context currently...
+        return context.space_data.params.use_library_browsing
+
     def draw(self, context):
         layout = self.layout
         space = context.space_data




More information about the Bf-blender-cvs mailing list