Fix keybinds being saved in native/localized form
Keybinds are now both saved and read in portable form and only converted to native one for display purposes, fixing them not being read correctly when certain languages are set. Also get rid of qPrintable() due to it using the system 8-bit codepage instead of UTF-8, and some unnecessary QString ↔ C string conversions Co-Authored-by: Cacodemon345 <wahil1976@outlook.com>
This commit is contained in:
@@ -90,7 +90,7 @@ KeyBinder::BindKey(QWidget* widget, QString CurValue)
|
||||
KeyBinder kb(widget);
|
||||
kb.setWindowTitle(tr("Bind Key"));
|
||||
kb.setFixedSize(kb.minimumSizeHint());
|
||||
kb.findChild<QKeySequenceEdit*>()->setKeySequence(QKeySequence::fromString(CurValue));
|
||||
kb.findChild<QKeySequenceEdit*>()->setKeySequence(QKeySequence::fromString(CurValue, QKeySequence::NativeText));
|
||||
kb.setEnabled(true);
|
||||
|
||||
if (kb.exec() == QDialog::Accepted) {
|
||||
|
||||
Reference in New Issue
Block a user