forked from Mirrors/openclonk
Fix editor keyboard input on FreeBSD (hopefully)
Assuming keyboard scancodes on FreeBSD are the same as on Linux.stable-8
parent
2159895280
commit
32df251d2e
|
@ -356,12 +356,11 @@ static C4KeyCode QtKeyToUnixScancode(const QKeyEvent &event)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
// Otherwise rely on native scan code to be the same on all platforms
|
// Otherwise rely on native scan code to be the same on all platforms
|
||||||
#ifdef Q_OS_LINUX
|
#if defined(USE_WIN32_WINDOWS) || defined(Q_OS_DARWIN)
|
||||||
return event.nativeScanCode() - 8;
|
|
||||||
#elif defined(Q_OS_DARWIN)
|
|
||||||
return event.nativeScanCode();
|
return event.nativeScanCode();
|
||||||
#else
|
#else
|
||||||
return event.nativeScanCode();
|
// Linux, FreeBSD, maybe others?
|
||||||
|
return event.nativeScanCode() - 8;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue