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

Event field "which" differs for ControllerDeviceAdded and ControllerDeviceRemoved #906

Closed
Bastczuak opened this issue Jul 29, 2019 · 5 comments
Labels

Comments

@Bastczuak
Copy link
Contributor

Bastczuak commented Jul 29, 2019

Hey,

while implementing the events ControllerDeviceAdded and ControllerDeviceRemoved , I realized that they have different data types for the which field.

One is u32 the other one is i32 https://rust-sdl2.github.io/rust-sdl2/sdl2/event/enum.Event.html#variant.ControllerDeviceAdded.

Is that on purpose or a mistake? Because the official sdl wiki says its always sint32 https://wiki.libsdl.org/SDL_ControllerDeviceEvent.

Greetings

@Bastczuak Bastczuak changed the title Event field which differs for ControllerDeviceAdded and ControllerDeviceRemoved Event field "which" differs for ControllerDeviceAdded and ControllerDeviceRemoved Jul 29, 2019
@Cobrand
Copy link
Member

Cobrand commented Aug 8, 2019

It's probably a mistake! Almost all other "which" fields are i32, and the doc says it should be i32, so we can almost safely assume this.

@Cobrand Cobrand added the E-Easy label Aug 8, 2019
@Bastczuak
Copy link
Contributor Author

@Cobrand I can do this for you, if you want?!

@Cobrand
Copy link
Member

Cobrand commented Aug 8, 2019

Sure, that would help!

@Bastczuak
Copy link
Contributor Author

#907 Created a pull request for you.

@mnmaita
Copy link
Contributor

mnmaita commented Sep 28, 2019

Hey there @Cobrand ! Been using SDL2 for some time and came across the Rust bindings not so long ago. Was taking a look at the repo's Issues and noticed #907 was merged so I guess you could close this issue.

@Cobrand Cobrand closed this as completed Sep 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants