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

[v2.0 samples] SDL "keycodes" with "scancodes" #18

Merged
merged 1 commit into from Sep 16, 2019

Conversation

Ybalrid
Copy link
Contributor

@Ybalrid Ybalrid commented Sep 16, 2019

In SDL2, Scancodes were introduced. This keyboard representation does not move around with the keyboard layout and makes everything consistant.

When you use a non-qwerty keyboard, the alpha keys tend to be moved around. Scancodes makes so that, for example, the WASD keys will allways be placed at the right place.

This is a non issue on Windows as it always behaved that way, but on linux, Keycodes respect the current keyboard layout, so international users will have the samples running with the wrong keyboard mapping.

All of the alphabetical keys in the samples source code have been changed to scancodes. I did not change all the function key and other special characters as this will not change anything for theses keys and I wanted to keep the diff short.

In SDL2, Scancodes were introduced. This keyboard representation does not move around with the keyboard layout and makes everything consistant.

When you use a non-qwerty keyboard, the alpha keys tend to be moved around. Scancodes makes so that, for example, the WASD keys will allways be placed at the right place.

This is a non issue on Windows as it always behaved that way, but on linux, Keycodes respect the current keyboard layout, so international users will have the samples running with the wrong keyboard mapping.

All of the alphabetical keys in the samples source code have been changed to scancodes. I did not change all the function key and other special characters as this will not change anything for theses keys and I wanted to keep the diff short.
@darksylinc darksylinc merged commit 0e2a132 into OGRECave:master Sep 16, 2019
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.

None yet

2 participants