(f)
| 1985 | // Used to add methods to editor and doc instances, wrapping them in |
| 1986 | // operations. |
| 1987 | function methodOp(f) { |
| 1988 | return function() { |
| 1989 | if (this.curOp) return f.apply(this, arguments); |
| 1990 | startOperation(this); |
| 1991 | try { return f.apply(this, arguments); } |
| 1992 | finally { endOperation(this); } |
| 1993 | }; |
| 1994 | } |
| 1995 | function docMethodOp(f) { |
| 1996 | return function() { |
| 1997 | var cm = this.cm; |
no test coverage detected
searching dependent graphs…