mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-03 16:40:21 +01:00
fix(editor): dragging a point of a selected track no longer hands the drag to the gizmo, which jumped under the cursor and lifted the point in the plane of the screen; the gizmo is switched off while a point is dragged
This commit is contained in:
@@ -718,7 +718,10 @@ void editor_mode::render_track_gizmo()
|
|||||||
if (operation == gizmo_operation::rotate)
|
if (operation == gizmo_operation::rotate)
|
||||||
gizmo = ImGuizmo::ROTATE_X | ImGuizmo::ROTATE_Y | ImGuizmo::ROTATE_Z;
|
gizmo = ImGuizmo::ROTATE_X | ImGuizmo::ROTATE_Y | ImGuizmo::ROTATE_Z;
|
||||||
ImGuizmo::AllowAxisFlip(operation != gizmo_operation::scale);
|
ImGuizmo::AllowAxisFlip(operation != gizmo_operation::scale);
|
||||||
|
if (m_point_drag.active)
|
||||||
|
ImGuizmo::Enable(false);
|
||||||
frame.manipulate(gizmo, m_track_gizmo, operation == gizmo_operation::translate ? m_gizmo_snap : 0.0f, &delta, operation == gizmo_operation::translate ? ImGuizmo::WORLD : ImGuizmo::LOCAL);
|
frame.manipulate(gizmo, m_track_gizmo, operation == gizmo_operation::translate ? m_gizmo_snap : 0.0f, &delta, operation == gizmo_operation::translate ? ImGuizmo::WORLD : ImGuizmo::LOCAL);
|
||||||
|
ImGuizmo::Enable(true);
|
||||||
ImGuizmo::AllowAxisFlip(true);
|
ImGuizmo::AllowAxisFlip(true);
|
||||||
|
|
||||||
if (false == ImGuizmo::IsUsing())
|
if (false == ImGuizmo::IsUsing())
|
||||||
|
|||||||
Reference in New Issue
Block a user