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

Add disabled status to FlxButton #3083

Closed
itulau opened this issue Mar 13, 2024 · 4 comments · Fixed by #3087
Closed

Add disabled status to FlxButton #3083

itulau opened this issue Mar 13, 2024 · 4 comments · Fixed by #3087

Comments

@itulau
Copy link
Contributor

itulau commented Mar 13, 2024

A very common feature that is missing from FlxButton which I think would be beneficial to have: A DISABLED state for FlxButton which would make the button ignore inputs and be displayed as being unable to be clicked (greyed out).

@itulau itulau changed the title Add disabled state to FlxButton Add disabled status to FlxButton Mar 14, 2024
itulau added a commit to itulau/flixel that referenced this issue Mar 14, 2024
Geokureli added a commit that referenced this issue Mar 18, 2024
* Add disabled status to FlxButton (#3083)

* create FlxButtonState enum

* fix unit tests

---------

Co-authored-by: George FunBook <[email protected]>
@Vortex2Oblivion
Copy link
Contributor

Would it be a good idea to add a disabled state to more flixel ui stuff
Like FlxUICheckBox for example?
Would need to make a pr on the flixel addons and ui repositories too ofc.

@Geokureli
Copy link
Member

Geokureli commented Mar 20, 2024

Would it be a good idea to add a disabled state to more flixel ui stuff Like FlxUICheckBox for example? Would need to make a pr on the flixel addons and ui repositories too ofc.

We discuss this in #3087. The changes are being made here: itulau/flixel-ui@601bf1f

@itulau
Copy link
Contributor Author

itulau commented Mar 20, 2024

Yes, https://github.com/itulau/flixel-ui/tree/flx-button-disabled contains my latest changes which should probably remove some issues related to adding the new disabled status. What I'm missing now is a demo to test those changes, which is becoming a bit tricky since I don't use flixel-ui's classes that much so I'm not sure where to begin.

@Geokureli
Copy link
Member

Geokureli commented Mar 21, 2024

I don't use flixel-ui's classes that much so I'm not sure where to begin.

Try some of the demos:

Also, in your branch, I'm wondering if the toggle button graphic should have 2 disabled states, seeing how it has 2 of every other kind?

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

Successfully merging a pull request may close this issue.

3 participants