[Bf-python] udpdate enum

Campbell Barton ideasman42 at gmail.com
Thu May 26 10:17:46 CEST 2011


This seems similar to your previous question,
it sounds like you want a dynamic enum still, and from my previous
mail, we don't support them yet from python.

2011/5/26 Yuniel Castro González <ycastrog at estudiantes.uci.cu>:
> Hi for all.
> I have an operator that shows an enum(combobox) with default element ('a' in this case), but I need change this value when I execute the operator (change 'a' by 'b' in this case). This is the idea but this operator doesn't satisfy me.
> How can I do????
> Thanks in advance.
>
> *******************************************
>
> class OBJECT_OT_view_lists(bpy.types.Operator):
>    bl_idname......
>
>    subdivide = [('a','a','a')]
>    subdivides = EnumProperty(name="Groups", description="Generated groups", items=subdivide)
>
>    def draw(self, context):
>        layout = self.layout
>        row = layout.row()
>        row.prop(self, 'subdivides')
>
>    def execute(self, context):
>        subdivide = [('b','b','b')]
>        return {'FINISHED'}
>
> --
>
>
>
>
>
>
>
>
> Yuniel
> _______________________________________________
> Bf-python mailing list
> Bf-python at blender.org
> http://lists.blender.org/mailman/listinfo/bf-python
>



-- 
- Campbell



More information about the Bf-python mailing list