From 45123a71578c29d24fcd1d660cd0b0d5d0673f47 Mon Sep 17 00:00:00 2001 From: WestLangley Date: Wed, 4 Nov 2015 18:06:29 -0500 Subject: [PATCH] OrbitControls: Restore mouseout listener --- examples/js/controls/OrbitControls.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/examples/js/controls/OrbitControls.js b/examples/js/controls/OrbitControls.js index 500187b838faa3..7b814b40fbfa84 100644 --- a/examples/js/controls/OrbitControls.js +++ b/examples/js/controls/OrbitControls.js @@ -488,6 +488,7 @@ document.addEventListener( 'mousemove', onMouseMove, false ); document.addEventListener( 'mouseup', onMouseUp, false ); + document.addEventListener( 'mouseout', onMouseUp, false ); scope.dispatchEvent( startEvent ); } @@ -559,6 +560,7 @@ document.removeEventListener( 'mousemove', onMouseMove, false ); document.removeEventListener( 'mouseup', onMouseUp, false ); + document.removeEventListener( 'mouseout', onMouseUp, false ); scope.dispatchEvent( endEvent ); state = STATE.NONE; @@ -786,6 +788,7 @@ document.removeEventListener( 'mousemove', onMouseMove, false ); document.removeEventListener( 'mouseup', onMouseUp, false ); + document.removeEventListener( 'mouseout', onMouseUp, false ); window.removeEventListener( 'keydown', onKeyDown, false );