(lineView)
| 916 | } |
| 917 | |
| 918 | function updateLineBackground(lineView) { |
| 919 | var cls = lineView.bgClass ? lineView.bgClass + " " + (lineView.line.bgClass || "") : lineView.line.bgClass; |
| 920 | if (cls) cls += " CodeMirror-linebackground"; |
| 921 | if (lineView.background) { |
| 922 | if (cls) lineView.background.className = cls; |
| 923 | else { lineView.background.parentNode.removeChild(lineView.background); lineView.background = null; } |
| 924 | } else if (cls) { |
| 925 | var wrap = ensureLineWrapped(lineView); |
| 926 | lineView.background = wrap.insertBefore(elt("div", null, cls), wrap.firstChild); |
| 927 | } |
| 928 | } |
| 929 | |
| 930 | // Wrapper around buildLineContent which will reuse the structure |
| 931 | // in display.externalMeasured when possible. |
no test coverage detected