mirror of
https://github.com/curioustorvald/tsvm.git
synced 2026-06-06 05:28:31 +09:00
shell now accepts envvar KEYBOARD and changes key layout on the fly
This commit is contained in:
@@ -426,7 +426,7 @@ con.KEY_INSERT = 210;
|
|||||||
con.KEY_DELETE = 211;
|
con.KEY_DELETE = 211;
|
||||||
con.KEY_BACKSPACE = 8;
|
con.KEY_BACKSPACE = 8;
|
||||||
con.KEY_TAB = 9;
|
con.KEY_TAB = 9;
|
||||||
con.KEY_RETURN = 13;
|
con.KEY_RETURN = 10;
|
||||||
con.getch = function() {
|
con.getch = function() {
|
||||||
return sys.readKey();
|
return sys.readKey();
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -319,6 +319,10 @@ shell.coreutils = {
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
_TVDOS.variables[key] = shell.replaceVarCall(value);
|
_TVDOS.variables[key] = shell.replaceVarCall(value);
|
||||||
|
|
||||||
|
// if key is KEYBOARD, reload the keyboard layout
|
||||||
|
if ("KEYBOARD" == key)
|
||||||
|
input.changeKeyLayout(_TVDOS.variables.KEYBOARD || "us_qwerty");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user