forked from mozilla/gecko-dev
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug 1624011 - Make constructor of
AlignStateAtSelection
not assert …
…when there is no selection ranges r=m_kato `AlignStateAtSelection` class is instantiated outside of editor class so that we shouldn't make each user guarantee that there is selection range (fortunately, the putting off cost is really low). And as far as I tested, Blink and WebKit does not throw exception when `Document.qeuryCommand*("justify*")` is called without selection ranges. So, this patch also prevents exception in this situation. Differential Revision: https://phabricator.services.mozilla.com/D68755 --HG-- extra : moz-landing-system : lando
- Loading branch information
1 parent
1cc1c59
commit 72cf6dc
Showing
5 changed files
with
29 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<html> | ||
<head> | ||
<script> | ||
window.addEventListener('load', () => { | ||
document.designMode = 'on' | ||
const selection = document.getSelection() | ||
selection.empty() | ||
document.queryCommandIndeterm('justifyFull') | ||
}) | ||
</script> | ||
</head> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -121,3 +121,4 @@ load 1574544.html | |
load 1596516.html | ||
load 1618906.html | ||
load 1623913.html | ||
load 1624011.html |