diff --git a/lib/codemirror.js b/lib/codemirror.js index 476ab2e6e5..7be2fac1db 100644 --- a/lib/codemirror.js +++ b/lib/codemirror.js @@ -4419,7 +4419,7 @@ // Revert a change stored in a document's history. function makeChangeFromHistory(doc, type, allowSelectionOnly) { - if (doc.cm && doc.cm.state.suppressEdits) return; + if (doc.cm && doc.cm.state.suppressEdits && !allowSelectionOnly) return; var hist = doc.history, event, selAfter = doc.sel; var source = type == "undo" ? hist.done : hist.undone, dest = type == "undo" ? hist.undone : hist.done;