Skip to content

Commit 35c0b2c

Browse files
author
David Kline
authored
Merge pull request #3719 from keveleigh/input-system-focus-bug
Fix focus bug in MixedRealityInputSystem.cs
2 parents 1afe596 + 0e2ab6f commit 35c0b2c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Assets/MixedRealityToolkit.Services/InputSystem/MixedRealityInputSystem.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -557,10 +557,11 @@ public void RaiseSourceLost(IMixedRealityInputSource source, IMixedRealityContro
557557
DetectedControllers.Remove(controller);
558558
}
559559

560-
FocusProvider?.OnSourceLost(sourceStateEventData);
561-
562560
// Pass handler through HandleEvent to perform modal/fallback logic
561+
// Events have to be handled before FocusProvider.OnSourceLost since they won't be passed on without a focused object
563562
HandleEvent(sourceStateEventData, OnSourceLostEventHandler);
563+
564+
FocusProvider?.OnSourceLost(sourceStateEventData);
564565
}
565566

566567
private static readonly ExecuteEvents.EventFunction<IMixedRealitySourceStateHandler> OnSourceLostEventHandler =

0 commit comments

Comments
 (0)