Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-04-19 09:13:56 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-04-19 09:13:56 +0300
commit54d8faa93a4dee556b12ef1ec3c607d5a72f396a (patch)
tree7139153b44d567d7f138fc55381c137255e625ea
parentad4cbc5a58fec30ce52592cdeb5e3eaafc6a2c24 (diff)
Cleanup: remove redundant poll functions
-rw-r--r--release/scripts/startup/bl_ui/properties_data_shaderfx.py11
-rw-r--r--release/scripts/startup/bl_ui/properties_grease_pencil_common.py4
-rw-r--r--release/scripts/startup/bl_ui/space_topbar.py4
-rw-r--r--release/scripts/startup/bl_ui/space_view3d.py8
4 files changed, 6 insertions, 21 deletions
diff --git a/release/scripts/startup/bl_ui/properties_data_shaderfx.py b/release/scripts/startup/bl_ui/properties_data_shaderfx.py
index 5ada588e31a..fce86446dfc 100644
--- a/release/scripts/startup/bl_ui/properties_data_shaderfx.py
+++ b/release/scripts/startup/bl_ui/properties_data_shaderfx.py
@@ -30,11 +30,12 @@ class ShaderFxButtonsPanel:
class DATA_PT_shader_fx(ShaderFxButtonsPanel, Panel):
bl_label = "Effects"
- @classmethod
- def poll(cls, context):
- return True
- ob = context.object
- return ob and ob.type == 'GPENCIL'
+ # Unused: always show for now.
+
+ # @classmethod
+ # def poll(cls, context):
+ # ob = context.object
+ # return ob and ob.type == 'GPENCIL'
def draw(self, context):
layout = self.layout
diff --git a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
index 1fd106fbe35..14c616d14d5 100644
--- a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
+++ b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
@@ -84,10 +84,6 @@ class AnnotationDrawingToolsPanel:
bl_category = "Annotation"
bl_region_type = 'TOOLS'
- @classmethod
- def poll(cls, _context):
- return True
-
def draw(self, context):
layout = self.layout
diff --git a/release/scripts/startup/bl_ui/space_topbar.py b/release/scripts/startup/bl_ui/space_topbar.py
index 79769f1597c..dade943ffd2 100644
--- a/release/scripts/startup/bl_ui/space_topbar.py
+++ b/release/scripts/startup/bl_ui/space_topbar.py
@@ -663,10 +663,6 @@ class TOPBAR_PT_name(Panel):
bl_label = "Rename Active Item"
bl_ui_units_x = 14
- @classmethod
- def poll(cls, _context):
- return True
-
def draw(self, context):
layout = self.layout
diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py
index 0b7a717746f..3ce892dbd83 100644
--- a/release/scripts/startup/bl_ui/space_view3d.py
+++ b/release/scripts/startup/bl_ui/space_view3d.py
@@ -5082,10 +5082,6 @@ class VIEW3D_PT_shading_options_shadow(Panel):
bl_space_type = 'VIEW_3D'
bl_region_type = 'HEADER'
- @classmethod
- def poll(cls, _context):
- return True
-
def draw(self, context):
layout = self.layout
layout.use_property_split = True
@@ -5102,10 +5098,6 @@ class VIEW3D_PT_shading_options_ssao(Panel):
bl_space_type = 'VIEW_3D'
bl_region_type = 'HEADER'
- @classmethod
- def poll(cls, _context):
- return True
-
def draw(self, context):
layout = self.layout
layout.use_property_split = True