Cursor locks to rotating the camera on mouse up outside of iframe

Small update: I’m getting the pointer up event outside of the iframe simply by this:
document.addEventListener('pointerup', function(event) { }

I read about a similar issue in this thread: https://forum.babylonjs.com/t/arccamera-iframe-mouseup-not-triggered/9251
But scene.simulatePointerUp() doesn’t work… Looks like scene.pick(1000, 500) doesn’t work as a parameter. The simulated event then still shows x: 0 y: 0. But even then it should still stop the rotation?

Another approach was using:

var clickEvent = document.createEvent ('MouseEvents');
clickEvent.initEvent ("pointerup", true, true);
canvas.dispatchEvent (clickEvent);

Here the event somewhat works. Looks like its fired at (0, 0), since the model rotates towards there. And you guessed it, the rotation is still locked, that’s probably why it rotates. But in the end the pointer up event doesn’t seem to cancel the rotation lock :confused: .