Hi,
I’ve been browsing the forum and docs, but am hoping that someone can fill me in here.
I’m trying to move some of the dropdown menu commands into panel buttons for convenience sake.
But I’m running into the Redo panel not showing up when I run the menu command from a button.
I can see the python code is being triggered in the Command Window, but I don’t get the Redo panel.
I did add the bl_options tag and even the bpy.ops.ed.undo_push() option I found being mentioned here, but it’s not working. I haven’t been able to find any other working suggestions, so hopefully someone can point me in the right direction…
Here’s one example:
class Randomize_Obj (bpy.types.Operator):
#Randomize LRS of Selected Objects
bl_idname = "rwtools.randomize_obj";
bl_label = "Randomize";
bl_description = "Randomize LRS Objects";
bl_options = {"REGISTER", "UNDO"}
@classmethod
def poll (cls, context):
return bpy.context.active_object is not None;
def execute(self, context):
bpy.ops.ed.undo_push()
bpy.ops.object.randomize_transform()
print("Randomized SRT for Objects");
return {'FINISHED'};
cheers for any tips, as I’m a bit stuck atm.
rob