mirror of
https://github.com/CopterExpress/clever-show.git
synced 2026-05-30 00:39:32 +00:00
Addon: Don't show led panell in empty materials
This commit is contained in:
@@ -7,6 +7,11 @@ class LedPanel(Panel):
|
||||
bl_region_type = 'WINDOW'
|
||||
bl_context = "material"
|
||||
|
||||
@classmethod
|
||||
def poll(cls, context):
|
||||
mat = context.material
|
||||
return mat and not mat.grease_pencil
|
||||
|
||||
def draw_header(self, context):
|
||||
self.layout.prop(context.material.led, "is_led", text="")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user