(doc, handle, changeType, op)
| 4771 | // returning the number and optionally registering the line as |
| 4772 | // changed. |
| 4773 | function changeLine(doc, handle, changeType, op) { |
| 4774 | var no = handle, line = handle; |
| 4775 | if (typeof handle == "number") line = getLine(doc, clipLine(doc, handle)); |
| 4776 | else no = lineNo(handle); |
| 4777 | if (no == null) return null; |
| 4778 | if (op(line, no) && doc.cm) regLineChange(doc.cm, no, changeType); |
| 4779 | return line; |
| 4780 | } |
| 4781 | |
| 4782 | // Helper for deleting text near the selection(s), used to implement |
| 4783 | // backspace, delete, and similar functionality. |
no test coverage detected