Page MenuHome

Mirror operator fails with EXEC_DEFAULT
Closed, ResolvedPublic

Description

Blender Version
Broken: rB1bfbfa281046
Working: rB1bfbfa281046~
Also Broken: Blender 2.79

Short description of error
I want to call the Mirror operator from the UI and have it apply immediately. This is normally done by setting the operator context to EXEC_DEFAULT or EXEC_REGION_WIN. However, this doesn't work with the Mirror operator.

Exact steps for others to reproduce the error

1: Apply this patch to change the 3D View Mirror menu to use EXEC_REGION_WIN:

2: Build and open Blender
3: Use Object > Mirror > Mirror X.
4: Mirroring fails

Also note that the redo panel doesn't include any toggles to mirror anything
And lastly, changing the redo options to tweak the mirror orientation doesn't work correctly (it either does nothing or mirrors on all axes at once)

Event Timeline

For the records, users can reproduce this also by using bpy.ops.transform.mirror(). It basically fails to run via exec even when the constraint axis are set.

@Dalai Felinto (dfelinto) Ah great, wasn't sure how to write the report in a more useful way.

Dalai Felinto (dfelinto) triaged this task as Confirmed, Medium priority.

@William Reynish (billreynish) while the patch does nothing to the Redo panel in regard to showing the constraint axis, it allows you now to successfully change the orientation there.