mirror of
https://github.com/fastmail/Squire.git
synced 2024-12-22 07:13:08 -05:00
Always call setSelection after bookmarking.
IE and Safari 5 loses the selection during the bookmarking process, so we must always explicitly reset the selection after recording an undo state (which adds a bookmark).
This commit is contained in:
parent
6927928a79
commit
a12f6905a5
1 changed files with 2 additions and 0 deletions
|
@ -1689,6 +1689,7 @@
|
|||
if ( !notWS.test( text.charAt( range.startOffset - 1 ) ) ) {
|
||||
recordUndoState( range );
|
||||
getRangeAndRemoveBookmark( range );
|
||||
setSelection( range );
|
||||
}
|
||||
setTimeout( afterDelete, 0 );
|
||||
}
|
||||
|
@ -1741,6 +1742,7 @@
|
|||
if ( !notWS.test( text.charAt( range.startOffset ) ) ) {
|
||||
recordUndoState( range );
|
||||
getRangeAndRemoveBookmark( range );
|
||||
setSelection( range );
|
||||
}
|
||||
setTimeout( afterDelete, 0 );
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue