(f)
| 3772 | this.node = node; |
| 3773 | }; |
| 3774 | function widgetOperation(f) { |
| 3775 | return function() { |
| 3776 | var withOp = !this.cm.curOp; |
| 3777 | if (withOp) startOperation(this.cm); |
| 3778 | try {var result = f.apply(this, arguments);} |
| 3779 | finally {if (withOp) endOperation(this.cm);} |
| 3780 | return result; |
| 3781 | }; |
| 3782 | } |
| 3783 | LineWidget.prototype.clear = widgetOperation(function() { |
| 3784 | var ws = this.line.widgets, no = lineNo(this.line); |
| 3785 | if (no == null || !ws) return; |
no test coverage detected