-
Notifications
You must be signed in to change notification settings - Fork 317
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FIX: ISXB-808 scroll wheel event system different than ui builder #1959
Merged
benoitalain
merged 39 commits into
develop
from
isxb-808-scrollwheeleventsystemdifferentthanuibuilder
Jul 17, 2024
Merged
FIX: ISXB-808 scroll wheel event system different than ui builder #1959
benoitalain
merged 39 commits into
develop
from
isxb-808-scrollwheeleventsystemdifferentthanuibuilder
Jul 17, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…08-scrollwheeleventsystemdifferentthanuibuilder # Conflicts: # Packages/com.unity.inputsystem/CHANGELOG.md # Packages/com.unity.inputsystem/InputSystem/Plugins/UI/InputSystemUIInputModule.cs
…om:Unity-Technologies/InputSystem into isxb-704-scrollwheelwindowsrawvaluesupport # Conflicts: # Packages/com.unity.inputsystem/InputSystem/Editor/Settings/InputSettingsProvider.cs
…08-scrollwheeleventsystemdifferentthanuibuilder # Conflicts: # Packages/com.unity.inputsystem/CHANGELOG.md # Packages/com.unity.inputsystem/InputSystem/Plugins/UI/InputSystemUIInputModule.cs
…08-scrollwheeleventsystemdifferentthanuibuilder
…08-scrollwheeleventsystemdifferentthanuibuilder
…nto isxb-808-scrollwheeleventsystemdifferentthanuibuilder # Conflicts: # Assets/Tests/InputSystem/Plugins/UITests.cs # Assets/Tests/InputSystem/Unity.InputSystem.Tests.asmdef # Packages/com.unity.inputsystem/InputSystem/Plugins/UI/InputSystemUIInputModule.cs # Packages/com.unity.inputsystem/InputSystem/Unity.InputSystem.asmdef
…nto isxb-808-scrollwheeleventsystemdifferentthanuibuilder # Conflicts: # Packages/com.unity.inputsystem/CHANGELOG.md
benoitalain
changed the title
Isxb 808 scrollwheeleventsystemdifferentthanuibuilder
FIX: ISXB-808 scroll wheel event system different than ui builder
Jul 16, 2024
jfreire-unity
approved these changes
Jul 16, 2024
…of github.com:Unity-Technologies/InputSystem into isxb-808-scrollwheeleventsystemdifferentthanuibuilder
benoitalain
commented
Jul 17, 2024
@@ -116,6 +116,24 @@ internal GameObject localMultiPlayerRoot | |||
set => m_LocalMultiPlayerRoot = value; | |||
} | |||
|
|||
/// <summary> | |||
/// A multiplier value that allows you adjust the scroll wheel speed sent to uGUI (Unity UI) components. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
that allows you adjust
that allows you to adjust
duckets
approved these changes
Jul 17, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved with docs amendments
benoitalain
force-pushed
the
isxb-808-scrollwheeleventsystemdifferentthanuibuilder
branch
from
July 17, 2024 19:36
68a9289
to
9d54366
Compare
benoitalain
deleted the
isxb-808-scrollwheeleventsystemdifferentthanuibuilder
branch
July 17, 2024 20:57
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Fixes ISXB-808. Based on recently landed trunk PR.
Details of what was changed and the thought process can be found in these Google Documents:
Changes made
This PR makes scroll delta values reaching UI Toolkit as uniform as possible between different platforms and between editor or runtime. The standard used is that of the Windows Editor, i.e. the same text in an TextField should scroll by the same amount in an EditorWindow than in a runtime panel, with or without uGUI interoperability.
Since legacy input is still supported in Unity 6, we make the InputSystem match the scaling of the legacy input by default. However, we also introduce a new
scrollDeltaPerTick
property API to allow users to fall back on the scroll factor that we had in InputSystem package version <= 1.4, by setting it to a value of6
.Testing
Manually tested the changes. Modified existing unit test and added one for the newly introduced API.
Risk
This PR yet again changes the scroll factor for existing user projects without any notification about it. Fortunately, they can very easily tweak it back to whatever they had, but this may still come as a surprise to them. On the other hand, the new setup is much much better for new projects, and for existing projects it's probably better too, allowing users to remove their workaround for the previously bad scroll factors.
Checklist
Before review:
Changed
,Fixed
,Added
sections.Area_CanDoX
,Area_CanDoX_EvenIfYIsTheCase
,Area_WhenIDoX_AndYHappens_ThisIsTheResult
.During merge:
NEW: ___
.FIX: ___
.DOCS: ___
.CHANGE: ___
.RELEASE: 1.1.0-preview.3
.After merge: