After edits that affect an inline editor, we try to resync the set of hidden/shown lines in CodeMirror to match what we think the visible range to be. But we were only doing that in the case where the edit came from a different editor. We also need to do it when the edit comes from our own editor. Ordinary edits can't affect lines outside of the visible range, but undo/redo can (because they can cause changes to other areas of the underlying document).
Issue by njx Thursday Oct 11, 2012 at 22:23 GMT Originally opened as https://github.com/adobe/brackets/pull/1817
After edits that affect an inline editor, we try to resync the set of hidden/shown lines in CodeMirror to match what we think the visible range to be. But we were only doing that in the case where the edit came from a different editor. We also need to do it when the edit comes from our own editor. Ordinary edits can't affect lines outside of the visible range, but undo/redo can (because they can cause changes to other areas of the underlying document).
njx included the following code: https://github.com/adobe/brackets/pull/1817/commits