Skip to content
Snippets Groups Projects
Commit adcfbf4d authored by Sybren A. Stüvel's avatar Sybren A. Stüvel
Browse files

Pose Library: explain why the 'for keymap' operators are there

The for-keymap version of the apply/blend operators take the Window
Manager's `poselib_flipped` property, and passes it to the regular
apply/blend operator. This makes it possible to bind a key to the
operator and still have it respect the global "Flip Pose" checkbox.

This behaviour was already in, this commit just adds a comment that
explains this.

No functional changes.
parent 2b99e744
No related branches found
No related tags found
No related merge requests found
...@@ -399,6 +399,10 @@ class POSELIB_OT_pose_asset_select_bones(PoseAssetUser, Operator): ...@@ -399,6 +399,10 @@ class POSELIB_OT_pose_asset_select_bones(PoseAssetUser, Operator):
return cls.bl_description.replace("Select", "Deselect") return cls.bl_description.replace("Select", "Deselect")
# This operator takes the Window Manager's `poselib_flipped` property, and
# passes it to the `POSELIB_OT_blend_pose_asset` operator. This makes it
# possible to bind a key to the operator and still have it respect the global
# "Flip Pose" checkbox.
class POSELIB_OT_blend_pose_asset_for_keymap(Operator): class POSELIB_OT_blend_pose_asset_for_keymap(Operator):
bl_idname = "poselib.blend_pose_asset_for_keymap" bl_idname = "poselib.blend_pose_asset_for_keymap"
bl_options = {"REGISTER", "UNDO"} bl_options = {"REGISTER", "UNDO"}
...@@ -421,6 +425,10 @@ class POSELIB_OT_blend_pose_asset_for_keymap(Operator): ...@@ -421,6 +425,10 @@ class POSELIB_OT_blend_pose_asset_for_keymap(Operator):
return bpy.ops.poselib.blend_pose_asset(context.copy(), 'INVOKE_DEFAULT', flipped=flipped) return bpy.ops.poselib.blend_pose_asset(context.copy(), 'INVOKE_DEFAULT', flipped=flipped)
# This operator takes the Window Manager's `poselib_flipped` property, and
# passes it to the `POSELIB_OT_apply_pose_asset` operator. This makes it
# possible to bind a key to the operator and still have it respect the global
# "Flip Pose" checkbox.
class POSELIB_OT_apply_pose_asset_for_keymap(Operator): class POSELIB_OT_apply_pose_asset_for_keymap(Operator):
bl_idname = "poselib.apply_pose_asset_for_keymap" bl_idname = "poselib.apply_pose_asset_for_keymap"
bl_options = {"REGISTER", "UNDO"} bl_options = {"REGISTER", "UNDO"}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment