Search Issue Tracker
Fixed
Fixed in 6000.0.61f1, 6000.2.9f1, 6000.3.0b7, 6000.4.0a3
Votes
0
Found in
6000.0.59f1
6000.2.7f1
6000.3.0b4
6000.4.0a1
Issue ID
UUM-121130
Regression
Yes
NullReferenceException is thrown when specific UI Toolkit focus changes are made
How to reproduce:
1. Open the ‘Bug.zip' project
2. Open the ‘Scene’ scene
3. Enter Play Mode
4. In the Game View select the 'Example1A’ button
5. Observe the result
Expected result: No errors are thrown in the console
Actual result: Errors are thrown in the console
Reproducible with: 2023.2.0a6, 6000.0.59f1, 6000.2.7f1, 6000.3.0b4, 6000.4.0a1
Not reproducible with: 2023.2.0a5
Reproducible on: macOS 26.0 (M1 Max)
Not reproducible on: No other environments tested
Notes: The issue is that SwitchFocus doesn't check whether the last focused element is still in a panel. In a specific case where there's pending focus changes, and you attempt to focus something while the previous element is being removed, and events are being processed, then the line of code `using (new EventDispatcherGate(oldFocusedVe.panel.dispatcher))` will attempt to access a null panel.
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Confusing validation message in Scoped Registries
- Compute shader is dispatched with unsupported workgroup size on multiple browsers when building the project for Web with WebGPU Graphics API
- Rotation Property collapses after changing Interpolation Type In Animation window
- It is possible to enter impossible Scope name in the Scope Registries of Package Manager Project settings
- 'EditorSceneManager.sceneCount' reports the wrong count when called by an 'EditorSceneManager.sceneClosed' event
Add comment