Skip to content

Conversation

ppandi-rythmos
Copy link

@ppandi-rythmos ppandi-rythmos commented Feb 27, 2024

Description

[Case ISXB-544] (https://jira.unity3d.com/browse/ISXB-544)

The GamepadButton enum has aliased enum members, and when detected by Unity as enum exposed as field and uses default property drawer, it causes confusing behaviour in the UI.
This PR tries to introduce a generic property drawers for aliased types, such that the UI now has aliased entries appended with names of the aliasing member in paranthesis (). This will be intuitive to the user and they would be aware that the selected value may be remapped on assignment

Changes made

A new property drawer for aliased enums has been introduced. It is made generic, so as to be extendable by any aliased enums in the Input System Package,

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.
    • FogBugz ticket attached, example ([case %number%](https://issuetracker.unity3d.com/issues/...)).
    • FogBugz is marked as "Resolved" with next release version correctly set.
  • 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.

@ppandi-rythmos ppandi-rythmos changed the title [ISXB-544] Fix for 1.6.X: Wrong value is chosen when selecting Gamepa… [ISXB-544] Fix for 1.6.X: Wrong value is chosen when selecting GamepadButton in a dropdown menu Feb 27, 2024
@ppandi-rythmos
Copy link
Author

@ekcoh Kindly have a look at this PR

@ekcoh
Copy link
Collaborator

ekcoh commented Feb 29, 2024

Thanks for the contribution @ppandi-rythmos, I have rerouted your changes via #1862 PR with some small modifications.

@ekcoh
Copy link
Collaborator

ekcoh commented Feb 29, 2024

I will close this PR when the other one lands.

@ekcoh ekcoh added waiting-for-review The issue is scheduled to be reviewed by the Unity maintainers ignore-replaced-by-other-pr and removed waiting-for-review The issue is scheduled to be reviewed by the Unity maintainers labels Feb 29, 2024
@ekcoh
Copy link
Collaborator

ekcoh commented Nov 6, 2024

This bug was fixed via another PR which originated from this one, will close this PR

@ekcoh ekcoh closed this Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants