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:
authorThomas Dinges <blender@dingto.org>2009-07-09 20:09:44 +0400
committerThomas Dinges <blender@dingto.org>2009-07-09 20:09:44 +0400
commit403dc0f25ad390cd4374f46797d52f9fa1a5b1e2 (patch)
tree40efdbfb1a58137ecdcc23963cbb6a79b8be9fb7 /release/ui/buttons_data_lamp.py
parentb00409e72d04fe9e710c25fb4f076d1e960328dc (diff)
2.5 Buttons:
* Fixed some Bugs from Commit 21458. * Show Preview Render only when there is an active id block. * Some Code Cleanup (especially in polls). Please try to keep it clean ;-)
Diffstat (limited to 'release/ui/buttons_data_lamp.py')
-rw-r--r--release/ui/buttons_data_lamp.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/release/ui/buttons_data_lamp.py b/release/ui/buttons_data_lamp.py
index 00d54aa5b70..e6e870bad5d 100644
--- a/release/ui/buttons_data_lamp.py
+++ b/release/ui/buttons_data_lamp.py
@@ -24,8 +24,8 @@ class DATA_PT_context_lamp(DataButtonsPanel):
__label__ = " "
def poll(self, context):
- return ((context.object and context.object.type == 'LAMP') or context.lamp)
-
+ return (context.object.type == 'LAMP')
+
def draw(self, context):
layout = self.layout
@@ -42,20 +42,14 @@ class DATA_PT_context_lamp(DataButtonsPanel):
split.template_ID(space, "pin_id")
split.itemS()
-
class DATA_PT_lamp(DataButtonsPanel):
__idname__ = "DATA_PT_lamp"
__label__ = "Lamp"
-
- def poll(self, context):
- return ((context.object and context.object.type == 'LAMP') or context.lamp)
def draw(self, context):
layout = self.layout
- ob = context.object
lamp = context.lamp
- space = context.space_data
layout.itemR(lamp, "type", expand=True)