Fix T47750: Edited hair: disconnect (and connect!) operator do not support redo.
As suggested by Sergey, do not register those anymore, this way we keep undo step, but user cannot 'redo' them (does not work, since cached DM in particle modifier data is not yet re-created by depsgraph update after undo when operator is redone). UI now has two buttons, one to (dic)connect current psys, the other to (dis)connect all. Also fixed similar issue with Connect Hair op.
This commit is contained in:
@@ -218,9 +218,13 @@ class PARTICLE_PT_context_particles(ParticleButtonsPanel, Panel):
|
||||
row.prop(part, "hair_step")
|
||||
if psys is not None and psys.is_edited:
|
||||
if psys.is_global_hair:
|
||||
layout.operator("particle.connect_hair")
|
||||
row = layout.row(align=True)
|
||||
row.operator("particle.connect_hair").all = False
|
||||
row.operator("particle.connect_hair", text="Connect All").all = True
|
||||
else:
|
||||
layout.operator("particle.disconnect_hair")
|
||||
row = layout.row(align=True)
|
||||
row.operator("particle.disconnect_hair").all = False
|
||||
row.operator("particle.disconnect_hair", text="Disconnect All").all = True
|
||||
elif psys is not None and part.type == 'REACTOR':
|
||||
split.enabled = particle_panel_enabled(context, psys)
|
||||
split.prop(psys, "reactor_target_object")
|
||||
|
Reference in New Issue
Block a user