mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-23 17:06:16 -04:00
[fix] Close modals when user clicks both on pad inner and outer
Also: split tests for automatic reconnection and regular modal tests.
This commit is contained in:
parent
0bd4169663
commit
4eec3763b4
3 changed files with 72 additions and 14 deletions
|
@ -3367,7 +3367,12 @@ function Ace2Inner(){
|
|||
evt.preventDefault();
|
||||
}
|
||||
}
|
||||
//hide the dropdownso
|
||||
|
||||
hideEditBarDropdowns();
|
||||
}
|
||||
|
||||
function hideEditBarDropdowns()
|
||||
{
|
||||
if(window.parent.parent.padeditbar){ // required in case its in an iframe should probably use parent.. See Issue 327 https://github.com/ether/etherpad-lite/issues/327
|
||||
window.parent.parent.padeditbar.toggleDropDown("none");
|
||||
}
|
||||
|
@ -4983,6 +4988,8 @@ function Ace2Inner(){
|
|||
$(document).on("keypress", handleKeyEvent);
|
||||
$(document).on("keyup", handleKeyEvent);
|
||||
$(document).on("click", handleClick);
|
||||
// dropdowns on edit bar need to be closed on clicks on both pad inner and pad outer
|
||||
$(outerWin.document).on("click", hideEditBarDropdowns);
|
||||
// Disabled: https://github.com/ether/etherpad-lite/issues/2546
|
||||
// Will break OL re-numbering: https://github.com/ether/etherpad-lite/pull/2533
|
||||
// $(document).on("cut", handleCut);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue