Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-08-09 02:31:18 +0300
committerCampbell Barton <campbell@blender.org>2022-08-09 02:31:18 +0300
commit8ed2abf856cbabd970d92aa3de850b0c70dccd0c (patch)
treed5a347ae3ad7cb123431c34b9046fe7f4e070001 /source/blender/editors/include/ED_view3d.h
parentb3fc8206be422a7d0155f0282c2493887e441dd3 (diff)
Fix missing undo steps for smooth-view operators
Support pushing undo steps for smooth-view operations that manipulate the camera. Now V3D_SmoothParams take optional undo arguments. Used for: - VIEW3D_OT_view_center_cursor - VIEW3D_OT_view_center_pick - VIEW3D_OT_view_orbit - VIEW3D_OT_view_roll - VIEW3D_OT_zoom_border Follow up fix for T92099.
Diffstat (limited to 'source/blender/editors/include/ED_view3d.h')
-rw-r--r--source/blender/editors/include/ED_view3d.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/editors/include/ED_view3d.h b/source/blender/editors/include/ED_view3d.h
index 931bb7be8bf..7d31950c869 100644
--- a/source/blender/editors/include/ED_view3d.h
+++ b/source/blender/editors/include/ED_view3d.h
@@ -1197,6 +1197,14 @@ bool ED_view3d_camera_lock_autokey(struct View3D *v3d,
void ED_view3d_lock_clear(struct View3D *v3d);
/**
+ * Check if creating an undo step should be performed if the viewport moves.
+ * \return true if #ED_view3d_camera_lock_undo_push would do an undo push.
+ */
+bool ED_view3d_camera_lock_undo_test(const View3D *v3d,
+ const RegionView3D *rv3d,
+ struct bContext *C);
+
+/**
* Create an undo step when the camera is locked to the view.
* \param str: The name of the undo step (typically #wmOperatorType.name should be used).
*