Fixed issue with slider focus and scroll input #38918
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Slider remained highlighted when you used scroll input to change another slider. Now the new slider grabs focus.
Before:
After:
Also I noticed there are quite significant differences between ScrollBar and Slider, even though the functionality is basically the same. For example, Scrollbar has a hovered and a pressed state - slider only has the former. Their input handling code is very different, which confused me a bit - why is it like this? Should Slider be reworked to function the same, but be more similar to ScrollBar? As in, try and synchronise their code so they are as similar as possible for ease of maintenance?