[Bf-extensions-cvs] SVN commit: /data/svn/bf-extensions [4132] contrib/py/scripts/addons/ io_atomblend_utilities/__init__.py:
Clemens Barth
barth at root-1.de
Thu Jan 3 14:10:04 CET 2013
Revision: 4132
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-extensions&revision=4132
Author: blendphys
Date: 2013-01-03 13:09:57 +0000 (Thu, 03 Jan 2013)
Log Message:
-----------
For the properties of the we now use bpy.props.PointerProperty(...) for its
initialization.
Blendphys.
Modified Paths:
--------------
contrib/py/scripts/addons/io_atomblend_utilities/__init__.py
Modified: contrib/py/scripts/addons/io_atomblend_utilities/__init__.py
===================================================================
--- contrib/py/scripts/addons/io_atomblend_utilities/__init__.py 2013-01-03 11:27:18 UTC (rev 4131)
+++ contrib/py/scripts/addons/io_atomblend_utilities/__init__.py 2013-01-03 13:09:57 UTC (rev 4132)
@@ -69,7 +69,7 @@
def draw(self, context):
layout = self.layout
- scn = context.scene.atom_blend[0]
+ scn = context.scene.atom_blend
row = layout.row()
row.label(text="Custom data file")
@@ -118,14 +118,14 @@
class PanelProperties(bpy.types.PropertyGroup):
def Callback_radius_type(self, context):
- scn = bpy.context.scene.atom_blend[0]
+ scn = bpy.context.scene.atom_blend
io_atomblend_utilities.choose_objects("radius_type",
scn.radius_how,
None,
None,
scn.radius_type)
def Callback_radius_pm(self, context):
- scn = bpy.context.scene.atom_blend[0]
+ scn = bpy.context.scene.atom_blend
io_atomblend_utilities.choose_objects("radius_pm",
scn.radius_how,
None,
@@ -178,7 +178,7 @@
bl_description = "Use color and radii values stored in the custom file"
def execute(self, context):
- scn = bpy.context.scene.atom_blend[0]
+ scn = bpy.context.scene.atom_blend
if scn.datafile == "":
return {'FINISHED'}
@@ -197,7 +197,7 @@
"You have to be in the 'Edit Mode'")
def execute(self, context):
- scn = bpy.context.scene.atom_blend[0]
+ scn = bpy.context.scene.atom_blend
io_atomblend_utilities.separate_atoms(scn)
@@ -211,7 +211,7 @@
bl_description = "Measure the distance between two objects"
def execute(self, context):
- scn = bpy.context.scene.atom_blend[0]
+ scn = bpy.context.scene.atom_blend
dist = io_atomblend_utilities.distance()
# Put the distance into the string of the output field.
@@ -226,7 +226,7 @@
bl_description = "Increase the radii of the atoms"
def execute(self, context):
- scn = bpy.context.scene.atom_blend[0]
+ scn = bpy.context.scene.atom_blend
io_atomblend_utilities.choose_objects("radius_all",
scn.radius_how,
scn.radius_all,
@@ -242,7 +242,7 @@
bl_description = "Decrease the radii of the atoms"
def execute(self, context):
- scn = bpy.context.scene.atom_blend[0]
+ scn = bpy.context.scene.atom_blend
io_atomblend_utilities.choose_objects("radius_all",
scn.radius_how,
1.0/scn.radius_all,
@@ -254,7 +254,7 @@
def register():
io_atomblend_utilities.read_elements()
bpy.utils.register_module(__name__)
- bpy.types.Scene.atom_blend = bpy.props.CollectionProperty(type=
+ bpy.types.Scene.atom_blend = bpy.props.PointerProperty(type=
PanelProperties)
def unregister():
More information about the Bf-extensions-cvs
mailing list