[Merged by Bors] - Rename ElementState to ButtonState#4314
Conversation
Member
|
I like this rename a lot. Eventually, I think we should unify the gamepad buttons to use this too, but that's a story for another PR. |
alice-i-cecile
approved these changes
Mar 24, 2022
bevy_input: Rename ElementState to ButtonStateElementState to ButtonState
Member
|
bors r+ |
bors bot
pushed a commit
that referenced
this pull request
Apr 24, 2022
# Objective - Part of the splitting process of #3692. ## Solution - Rename `ElementState` to `ButtonState` ## Reasons - The old name was too generic. - If something can be pressed it is automatically button-like (thanks to @alice-i-cecile for bringing it up in #3692). - The reason it is called `ElementState` is because that's how `winit` calls it. - It is used to define if a keyboard or mouse **button** is pressed or not. - Discussion in #3692. ## Changelog ### Changed - The `ElementState` type received a rename and is now called `ButtonState`. ## Migration Guide - The `ElementState` type received a rename and is now called `ButtonState`. To migrate you just have to change every occurrence of `ElementState` to `ButtonState`. Co-authored-by: KDecay <KDecayMusic@protonmail.com>
Contributor
ElementState to ButtonStateElementState to ButtonState
exjam
pushed a commit
to exjam/bevy
that referenced
this pull request
May 22, 2022
# Objective - Part of the splitting process of bevyengine#3692. ## Solution - Rename `ElementState` to `ButtonState` ## Reasons - The old name was too generic. - If something can be pressed it is automatically button-like (thanks to @alice-i-cecile for bringing it up in bevyengine#3692). - The reason it is called `ElementState` is because that's how `winit` calls it. - It is used to define if a keyboard or mouse **button** is pressed or not. - Discussion in bevyengine#3692. ## Changelog ### Changed - The `ElementState` type received a rename and is now called `ButtonState`. ## Migration Guide - The `ElementState` type received a rename and is now called `ButtonState`. To migrate you just have to change every occurrence of `ElementState` to `ButtonState`. Co-authored-by: KDecay <KDecayMusic@protonmail.com>
ItsDoot
pushed a commit
to ItsDoot/bevy
that referenced
this pull request
Feb 1, 2023
# Objective - Part of the splitting process of bevyengine#3692. ## Solution - Rename `ElementState` to `ButtonState` ## Reasons - The old name was too generic. - If something can be pressed it is automatically button-like (thanks to @alice-i-cecile for bringing it up in bevyengine#3692). - The reason it is called `ElementState` is because that's how `winit` calls it. - It is used to define if a keyboard or mouse **button** is pressed or not. - Discussion in bevyengine#3692. ## Changelog ### Changed - The `ElementState` type received a rename and is now called `ButtonState`. ## Migration Guide - The `ElementState` type received a rename and is now called `ButtonState`. To migrate you just have to change every occurrence of `ElementState` to `ButtonState`. Co-authored-by: KDecay <KDecayMusic@protonmail.com>
This file contains hidden or 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
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.
Objective
bevy_input#3692.Solution
ElementStatetoButtonStateReasons
bevy_input#3692).ElementStateis because that's howwinitcalls it.bevy_input#3692.Changelog
Changed
ElementStatetype received a rename and is now calledButtonState.Migration Guide
ElementStatetype received a rename and is now calledButtonState. To migrate you just have to change every occurrence ofElementStatetoButtonState.