mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-20 15:36:16 -04:00
much better chat focus toggle behavior
This commit is contained in:
parent
428b547d24
commit
19e83d5405
2 changed files with 20 additions and 4 deletions
|
@ -3636,6 +3636,7 @@ function Ace2Inner(){
|
|||
var charCode = evt.charCode;
|
||||
var keyCode = evt.keyCode;
|
||||
var which = evt.which;
|
||||
var altKey = evt.altKey;
|
||||
|
||||
// prevent ESC key
|
||||
if (keyCode == 27)
|
||||
|
@ -3718,11 +3719,11 @@ function Ace2Inner(){
|
|||
firstEditbarElement.focus();
|
||||
evt.preventDefault();
|
||||
}
|
||||
if ((!specialHandled) && isTypeForSpecialKey && keyCode == 67){
|
||||
if ((!specialHandled) && altKey && keyCode == 67){
|
||||
// Alt c focuses on the Chat window
|
||||
$(this).blur();
|
||||
parent.parent.chat.show();
|
||||
parent.parent.chat.focus();
|
||||
$(this).blur();
|
||||
evt.preventDefault();
|
||||
}
|
||||
if ((!specialHandled) && isTypeForSpecialKey && keyCode == 8)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue