Ignore numpad keys for keyToChar conversion
This commit is contained in:
@@ -68,22 +68,7 @@ char keyToChar(sf::Keyboard::Key key, bool isShift) {
|
||||
case kb::Return: return '\n';
|
||||
case kb::BackSpace: return '\b';
|
||||
case kb::Delete: return '\x7f';
|
||||
case kb::Numpad0: return '0';
|
||||
case kb::Numpad1: return '1';
|
||||
case kb::Numpad2: return '2';
|
||||
case kb::Numpad3: return '3';
|
||||
case kb::Numpad4: return '4';
|
||||
case kb::Numpad5: return '5';
|
||||
case kb::Numpad6: return '6';
|
||||
case kb::Numpad7: return '7';
|
||||
case kb::Numpad8: return '8';
|
||||
case kb::Numpad9: return '9';
|
||||
// TODO: Should have Equal here, but SFML doesn't distinguish between normal and keybad equal :/
|
||||
// Ditto for the decimal point.
|
||||
case kb::Divide: return '/';
|
||||
case kb::Multiply: return '*';
|
||||
case kb::Subtract: return '-';
|
||||
case kb::Add: return '+';
|
||||
// Skip numpad keys, those that we handle at all are handled separately anyway
|
||||
default: break;
|
||||
}
|
||||
return 0;
|
||||
|
@@ -69,22 +69,7 @@ char keyToChar(sf::Keyboard::Key key, bool isShift) {
|
||||
case kb::Return: return '\n';
|
||||
case kb::BackSpace: return '\b';
|
||||
case kb::Delete: return '\x7f';
|
||||
case kb::Numpad0: return '0';
|
||||
case kb::Numpad1: return '1';
|
||||
case kb::Numpad2: return '2';
|
||||
case kb::Numpad3: return '3';
|
||||
case kb::Numpad4: return '4';
|
||||
case kb::Numpad5: return '5';
|
||||
case kb::Numpad6: return '6';
|
||||
case kb::Numpad7: return '7';
|
||||
case kb::Numpad8: return '8';
|
||||
case kb::Numpad9: return '9';
|
||||
// TODO: Should have Equal here, but SFML doesn't distinguish between normal and keybad equal :/
|
||||
// Ditto for the decimal point.
|
||||
case kb::Divide: return '/';
|
||||
case kb::Multiply: return '*';
|
||||
case kb::Subtract: return '-';
|
||||
case kb::Add: return '+';
|
||||
// Skip numpad keys, those that we handle at all are handled separately anyway
|
||||
default: break;
|
||||
}
|
||||
return 0;
|
||||
|
@@ -67,22 +67,7 @@ char keyToChar(sf::Keyboard::Key key, bool isShift) {
|
||||
case kb::Return: return '\n';
|
||||
case kb::BackSpace: return '\b';
|
||||
case kb::Delete: return '\x7f';
|
||||
case kb::Numpad0: return '0';
|
||||
case kb::Numpad1: return '1';
|
||||
case kb::Numpad2: return '2';
|
||||
case kb::Numpad3: return '3';
|
||||
case kb::Numpad4: return '4';
|
||||
case kb::Numpad5: return '5';
|
||||
case kb::Numpad6: return '6';
|
||||
case kb::Numpad7: return '7';
|
||||
case kb::Numpad8: return '8';
|
||||
case kb::Numpad9: return '9';
|
||||
// TODO: Should have Equal here, but SFML doesn't distinguish between normal and keybad equal :/
|
||||
// Ditto for the decimal point.
|
||||
case kb::Divide: return '/';
|
||||
case kb::Multiply: return '*';
|
||||
case kb::Subtract: return '-';
|
||||
case kb::Add: return '+';
|
||||
// Skip numpad keys, those that we handle at all are handled separately anyway
|
||||
default: break;
|
||||
}
|
||||
return 0;
|
||||
|
Reference in New Issue
Block a user