MCPcopy
hub / github.com/deepch/RTSPtoWebRTC / getBordersSize

Function getBordersSize

web/static/js/bootstrap.bundle.js:1836–1841  ·  view source on GitHub ↗
(styles, axis)

Source from the content-addressed store, hash-verified

1834 */
1835
1836 function getBordersSize(styles, axis) {
1837 var sideA = axis === 'x' ? 'Left' : 'Top';
1838 var sideB = sideA === 'Left' ? 'Right' : 'Bottom';
1839
1840 return parseFloat(styles['border' + sideA + 'Width'], 10) + parseFloat(styles['border' + sideB + 'Width'], 10);
1841 }
1842
1843 function getSize(axis, body, html, computedStyle) {
1844 return Math.max(body['offset' + axis], body['scroll' + axis], html['client' + axis], html['offset' + axis], html['scroll' + axis], isIE(10) ? parseInt(html['offset' + axis]) + parseInt(computedStyle['margin' + (axis === 'Height' ? 'Top' : 'Left')]) + parseInt(computedStyle['margin' + (axis === 'Height' ? 'Bottom' : 'Right')]) : 0);

Callers 1

getBoundingClientRectFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected