Skip to content

Commit

Permalink
fix(RPS-932): Fixed race condition preventing joint jogging stop
Browse files Browse the repository at this point in the history
  • Loading branch information
evrys committed Nov 27, 2024
1 parent 4527fc2 commit 45a1ad6
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions src/components/jogging/JoggingJointRotationControl.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,6 @@ export const JoggingJointRotationControl = externalizeComponent(
}

function onPointerOut(ev: React.PointerEvent) {
// Prevent subelements of button from stopping jogging
if (ev.target !== ev.currentTarget) return

state.stopJogging()
}

Expand Down Expand Up @@ -137,7 +134,11 @@ export const JoggingJointRotationControl = externalizeComponent(
...(state.activeJoggingDir === "-" ? pressedButtonStyle : {}),
}}
>
<ChevronLeft />
<ChevronLeft
sx={{
"pointer-events": "none",
}}
/>
</IconButton>

<Stack
Expand Down Expand Up @@ -228,7 +229,11 @@ export const JoggingJointRotationControl = externalizeComponent(
...(state.activeJoggingDir === "+" ? pressedButtonStyle : {}),
}}
>
<ChevronRight />
<ChevronRight
sx={{
"pointer-events": "none",
}}
/>
</IconButton>
</Stack>
)
Expand Down

0 comments on commit 45a1ad6

Please sign in to comment.