File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed
Assets/MixedRealityToolkit.Services/InputSystem Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -77,10 +77,11 @@ public override void DeactivateModule()
7777 {
7878 MixedRealityToolkit . InputSystem . Unregister ( gameObject ) ;
7979
80- foreach ( IMixedRealityInputSource inputSource in MixedRealityToolkit . InputSystem . DetectedInputSources )
80+ foreach ( var p in pointerDataToUpdate )
8181 {
82- OnSourceLost ( inputSource ) ;
82+ pointerDataToRemove . Add ( p . Value ) ;
8383 }
84+ pointerDataToUpdate . Clear ( ) ;
8485
8586 // Process once more to handle pointer removals.
8687 Process ( ) ;
@@ -281,11 +282,8 @@ void OnSourceDetected(IMixedRealityInputSource inputSource)
281282
282283 void IMixedRealitySourceStateHandler . OnSourceLost ( SourceStateEventData eventData )
283284 {
284- OnSourceLost ( eventData . InputSource ) ;
285- }
285+ var inputSource = eventData . InputSource ;
286286
287- void OnSourceLost ( IMixedRealityInputSource inputSource )
288- {
289287 for ( int i = 0 ; i < inputSource . Pointers . Length ; i ++ )
290288 {
291289 var pointer = inputSource . Pointers [ i ] ;
You can’t perform that action at this time.
0 commit comments