Post #2176: I’m using the following code to delete depending on the mode I’m currently in.
📋 Metadata
- Author: actimelvanille
- Date: 2019-04-12 19:14:42
- Type:
bug_report - Quality Score: 7/10
- Replies (1): post_02177
🏷️ Tags
macro hotkeys intermediate unsolved
⚙️ Related PME Features
- Macro Editor
- Hotkey Configuration
- Python Scripting
💬 Content
I’m using the following code to delete depending on the mode I’m currently in.
vert_sel, edge_sel, face_sel = C.tool_settings.mesh_select_mode; vert_sel and bpy.ops.mesh.dissolve_verts() or edge_sel and bpy.ops.mesh.dissolve_edges(use_verts=True) or face_sel and bpy.ops.mesh.delete(type='FACE')
The problem is that if I do an “undo” PME executes two undos.
This seems to be the case for all PME hotkeys that have more than one “action”.
So bpy.ops.mesh.dissolve_edges(use_verts=True) works on it’s own.
But as soon as I add something else two undos will be executed.
Is there some kind of option I can enable to avoid this?