Skip to content

Commit 71717ef

Browse files
authored
UNDOTYPE_NEW needs to be called after
Kudo Andreas Block
1 parent 90b2afc commit 71717ef

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

plugins/py-liquid_painter_r12/py-liquid_painter_r12.pyp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,12 +132,12 @@ class LiquidTool(c4d.plugins.ToolData):
132132
if pTag is None:
133133
raise MemoryError("Failed to create a Phong Tag.")
134134

135-
# Adds an undo step
136-
doc.AddUndo(c4d.UNDO_NEW, metaball)
137-
138135
# Inserts the object in the active document and set it as active one.
139136
doc.InsertObject(metaball)
140137
doc.SetActiveObject(metaball)
138+
139+
# Adds an undo step
140+
doc.AddUndo(c4d.UNDOTYPE_NEW, metaball)
141141

142142
# Updates the Viewport (so the metaball is drawn)
143143
c4d.DrawViews(c4d.DA_ONLY_ACTIVE_VIEW | c4d.DA_NO_THREAD | c4d.DA_NO_ANIMATION)

0 commit comments

Comments
 (0)