mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-12-25 21:27:30 +01:00
Corrected InputEventKey::as_text to return a non-empty string for physical keys.
This commit is contained in:
parent
5f3aa5fbd0
commit
6c65c86669
@ -268,7 +268,14 @@ uint32_t InputEventKey::get_physical_scancode_with_modifiers() const {
|
|||||||
}
|
}
|
||||||
|
|
||||||
String InputEventKey::as_text() const {
|
String InputEventKey::as_text() const {
|
||||||
String kc = keycode_get_string(scancode);
|
String kc;
|
||||||
|
|
||||||
|
if (scancode == 0) {
|
||||||
|
kc = keycode_get_string(physical_scancode) + " (" + RTR("Physical") + ")";
|
||||||
|
} else {
|
||||||
|
kc = keycode_get_string(scancode);
|
||||||
|
}
|
||||||
|
|
||||||
if (kc == String()) {
|
if (kc == String()) {
|
||||||
return kc;
|
return kc;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user