(cm)
| 383 | // Prepare DOM reads needed to update the scrollbars. Done in one |
| 384 | // shot to minimize update/measure roundtrips. |
| 385 | function measureForScrollbars(cm) { |
| 386 | var d = cm.display, gutterW = d.gutters.offsetWidth; |
| 387 | var docH = Math.round(cm.doc.height + paddingVert(cm.display)); |
| 388 | return { |
| 389 | clientHeight: d.scroller.clientHeight, |
| 390 | viewHeight: d.wrapper.clientHeight, |
| 391 | scrollWidth: d.scroller.scrollWidth, clientWidth: d.scroller.clientWidth, |
| 392 | viewWidth: d.wrapper.clientWidth, |
| 393 | barLeft: cm.options.fixedGutter ? gutterW : 0, |
| 394 | docHeight: docH, |
| 395 | scrollHeight: docH + scrollGap(cm) + d.barHeight, |
| 396 | nativeBarWidth: d.nativeBarWidth, |
| 397 | gutterWidth: gutterW |
| 398 | }; |
| 399 | } |
| 400 | |
| 401 | function NativeScrollbars(place, scroll, cm) { |
| 402 | this.cm = cm; |
no test coverage detected