Merge pull request #18 from jhermsmeier/prevent-tab-focus-loss
keyboard: Prevent input focus loss if no completion found
This commit is contained in:
commit
ce20310e17
@ -17,9 +17,9 @@ function Keyboard()
|
|||||||
|
|
||||||
// Autocomplete with tab
|
// Autocomplete with tab
|
||||||
if(event.keyCode === 9){
|
if(event.keyCode === 9){
|
||||||
|
event.preventDefault();
|
||||||
var ac = ronin.terminal.find_autocomplete();
|
var ac = ronin.terminal.find_autocomplete();
|
||||||
if(ac){
|
if(ac){
|
||||||
event.preventDefault();
|
|
||||||
ronin.terminal.input.value += ac;
|
ronin.terminal.input.value += ac;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -105,7 +105,7 @@ function Keyboard()
|
|||||||
this.key_escape = function()
|
this.key_escape = function()
|
||||||
{
|
{
|
||||||
ronin.overlay.key_escape();
|
ronin.overlay.key_escape();
|
||||||
|
|
||||||
for(var key in ronin.modules){
|
for(var key in ronin.modules){
|
||||||
ronin.modules[key].key_escape();
|
ronin.modules[key].key_escape();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user