mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 16:32:18 +02:00
Revert "MDL-45239 editor_atto: The editor cannot be active if it is not the active element"
This reverts commit 05a7f9e749ac31a0a0c9e59a1e0ddab065ddc2f7.
This commit is contained in:
parent
066f0395a6
commit
6e4c18522d
@ -1001,11 +1001,6 @@ EditorSelection.prototype = {
|
||||
return false;
|
||||
}
|
||||
|
||||
// We can't be active if the editor doesn't have focus at the moment.
|
||||
if (!document.activeElement || document.activeElement !== this.editor) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check whether the range intersects the editor selection.
|
||||
range.selectNode(this.editor.getDOMNode());
|
||||
return range.intersectsRange(selection.getRangeAt(0));
|
||||
|
File diff suppressed because one or more lines are too long
@ -996,11 +996,6 @@ EditorSelection.prototype = {
|
||||
return false;
|
||||
}
|
||||
|
||||
// We can't be active if the editor doesn't have focus at the moment.
|
||||
if (!document.activeElement || document.activeElement !== this.editor) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check whether the range intersects the editor selection.
|
||||
range.selectNode(this.editor.getDOMNode());
|
||||
return range.intersectsRange(selection.getRangeAt(0));
|
||||
|
@ -108,11 +108,6 @@ EditorSelection.prototype = {
|
||||
return false;
|
||||
}
|
||||
|
||||
// We can't be active if the editor doesn't have focus at the moment.
|
||||
if (!document.activeElement || document.activeElement !== this.editor) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check whether the range intersects the editor selection.
|
||||
range.selectNode(this.editor.getDOMNode());
|
||||
return range.intersectsRange(selection.getRangeAt(0));
|
||||
|
Loading…
x
Reference in New Issue
Block a user