Post #122: oc

📋 Metadata

  • Author: roaoao
  • Date: 2016-04-11 03:04:26
  • Type: answer
  • Quality Score: 8/10
  • Reply to: post_00121

🏷️ Tags

pie-menu hotkeys advanced solved

  • Pie Menu Editor
  • Python Scripting
  • Command execution
  • Delayed Exec addon integration

💬 Content

oct:

How or can you recenter the cursor back to the initial mouse position after a swipe? I need the cursor to recenter on pie menu after a swipe is completed. Currently, selected element would move to the end of the mouse swipe which is not ideal for precision work. The workaround is to activate pie menu then click on the command.

Here is another workaround. Install ‘ Delayed Exec ’ add-on which will allow you to execute code after a swipe and use this script in Command tab:

O.wm.delayed_exec('INVOKE_DEFAULT', code="bpy.ops.transform.translate('INVOKE_DEFAULT', constraint_axis=(False, False, True), constraint_orientation='GLOBAL')")

Attachments

delayed_exec.zip (752 Bytes)


🔗 View on Blender Artists