()
| 19 | } |
| 20 | |
| 21 | clear() { |
| 22 | let cm = this.doc.cm, ws = this.line.widgets, line = this.line, no = lineNo(line) |
| 23 | if (no == null || !ws) return |
| 24 | for (let i = 0; i < ws.length; ++i) if (ws[i] == this) ws.splice(i--, 1) |
| 25 | if (!ws.length) line.widgets = null |
| 26 | let height = widgetHeight(this) |
| 27 | updateLineHeight(line, Math.max(0, line.height - height)) |
| 28 | if (cm) { |
| 29 | runInOp(cm, () => { |
| 30 | adjustScrollWhenAboveVisible(cm, line, -height) |
| 31 | regLineChange(cm, no, "widget") |
| 32 | }) |
| 33 | signalLater(cm, "lineWidgetCleared", cm, this, no) |
| 34 | } |
| 35 | } |
| 36 | |
| 37 | changed() { |
| 38 | let oldH = this.height, cm = this.doc.cm, line = this.line |
nothing calls this directly
no test coverage detected