From 7e7dfc17c25b008792a9aa8be24117bfa4e46744 Mon Sep 17 00:00:00 2001 From: Paul Elliott Date: Thu, 6 Nov 2025 18:22:40 -0500 Subject: [PATCH] fix: reverse arrow key and alt mouse slice direction For anatomical consistency. --- src/components/vtk/VtkSliceViewSlicingKeyManipulator.vue | 3 ++- src/composables/actions.ts | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/components/vtk/VtkSliceViewSlicingKeyManipulator.vue b/src/components/vtk/VtkSliceViewSlicingKeyManipulator.vue index 79452d9dd..b7cfa8797 100644 --- a/src/components/vtk/VtkSliceViewSlicingKeyManipulator.vue +++ b/src/components/vtk/VtkSliceViewSlicingKeyManipulator.vue @@ -66,7 +66,8 @@ const scroll = useMouseRangeManipulatorListener( 'vertical', sliceConfig.range, 1, - sliceConfig.slice.value + sliceConfig.slice.value, + -1 ); syncRef(scroll, sliceConfig.slice, { immediate: true }); diff --git a/src/composables/actions.ts b/src/composables/actions.ts index 7012bcedc..8c4d7970f 100644 --- a/src/composables/actions.ts +++ b/src/composables/actions.ts @@ -91,8 +91,8 @@ export const ACTION_TO_FUNC = { polygon: setTool(Tools.Polygon), select: setTool(Tools.Select), - nextSlice: changeSlice(1), - previousSlice: changeSlice(-1), + nextSlice: changeSlice(-1), + previousSlice: changeSlice(1), grabSlice: NOOP, // acts as a modifier key rather than immediate effect, so no-op decrementLabel: applyLabelOffset(-1),