diff --git a/app/lib/views/view.dart b/app/lib/views/view.dart index ee9e37b8ad28..53cdd7673d25 100644 --- a/app/lib/views/view.dart +++ b/app/lib/views/view.dart @@ -300,11 +300,16 @@ class _MainViewViewportState extends State await changeTemporaryTool( event.kind, event.buttons); } - getHandler() - .onPointerDown(event, getEventContext()); + if (_isScalingDisabled ?? true) { + getHandler() + .onPointerDown(event, getEventContext()); + } }, onPointerUp: (PointerUpEvent event) async { - getHandler().onPointerUp(event, getEventContext()); + if (_isScalingDisabled ?? true) { + getHandler() + .onPointerUp(event, getEventContext()); + } cubit.removePointer(event.pointer); cubit.removeButtons(); Future.sync(() => cubit.resetTemporaryHandler( @@ -323,12 +328,16 @@ class _MainViewViewportState extends State cubit.move(event.delta / transform.size); delayBake(); } - getHandler().onPointerGestureMove( - event, getEventContext()); + if (_isScalingDisabled ?? true) { + getHandler().onPointerGestureMove( + event, getEventContext()); + } return; } - getHandler() - .onPointerMove(event, getEventContext()); + if (_isScalingDisabled ?? true) { + getHandler() + .onPointerMove(event, getEventContext()); + } }, child: BlocBuilder( builder: (context, transform) => MouseRegion(