Skip to content
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

CHANGE: Add action map disable / enable to rebinding sample #2137

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

Secticide
Copy link
Collaborator

Description

When investigating ISXB-1396 and ultimately closing as by design; a possible improvement to our rebinding UI sample surfaced.

This PR changes the rebinding UI sample. When rebinding an action, the parent action map and the UI action map (in the project wide actions) are disabled. Considering the sample is intended to be used with older versions of Unity where project wide actions were not yet introduced, the input action asset has been manually added to the RebindActionUI script (and editor).

Testing status & QA

Tested this locally with Unity 2021.3.45f1 and 6. Also tested with keyboard & mouse and a Dualshock 4 controller (when wired). But all we're doing is disabling the action map so this would have been tested widely by other tests.

Overall Product Risks

  • Complexity: 0
  • Halo Effect: 0

Comments to reviewers

Let me know if the team would like the reference to the UI action map to be obtained a different way, currently this is collected from the assigned default action map when the component is enabled via a call to InputActionAsset.FindActionMap.

Checklist

Before review:

  • Changelog entry added.
    • Explains the change in Changed, Fixed, Added sections.
    • For API change contains an example snippet and/or migration example.
    • JIRA ticket linked, example (case %%). If it is a private issue, just add the case ID without a link.
    • Jira port for the next release set as "Resolved".
  • Tests added/changed, if applicable.
    • Functional tests Area_CanDoX, Area_CanDoX_EvenIfYIsTheCase, Area_WhenIDoX_AndYHappens_ThisIsTheResult.
    • Performance tests.
    • Integration tests.
  • Docs for new/changed API's.
    • Xmldoc cross references are set correctly.
    • Added explanation how the API works.
    • Usage code examples added.
    • The manual is updated, if needed.

During merge:

  • Commit message for squash-merge is prefixed with one of the list:
    • NEW: ___.
    • FIX: ___.
    • DOCS: ___.
    • CHANGE: ___.
    • RELEASE: 1.1.0-preview.3.

After merge:

  • Create forward/backward port if needed. If you are blocked from creating a forward port now please add a task to ISX-1444.

@Secticide Secticide self-assigned this Feb 18, 2025
@Secticide Secticide changed the title Add action map disable / enable to rebinding sample CHANGE: Add action map disable / enable to rebinding sample Feb 18, 2025
Copy link
Collaborator

@ritamerkl ritamerkl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Jak!

Copy link
Collaborator

@jfreire-unity jfreire-unity left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Thanks for adding this!
Added Paulius to do a sanity QA check

…et action map and the UI action map) when rebinding is in progress.
@Secticide Secticide force-pushed the improve-rebinding-sample branch from a0765fd to 83d7419 Compare February 21, 2025 10:37
@Secticide
Copy link
Collaborator Author

Rebased to ensure we're up to date with develop. Fingers crossed the tests run successfully this time.

I doubled checked the previously failing test and it definitely wasn't related to these changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants