MCPcopy Index your code
hub / github.com/SeleniumHQ/selenium / newScrollDim

Function newScrollDim

javascript/atoms/window.js:364–372  ·  view source on GitHub ↗
(positionDim, scrollDim, viewportDim)

Source from the content-addressed store, hash-verified

362 }
363
364 function newScrollDim(positionDim, scrollDim, viewportDim) {
365 if (positionDim < scrollDim) {
366 return positionDim;
367 } else if (positionDim >= scrollDim + viewportDim) {
368 return positionDim - viewportDim + 1;
369 } else {
370 return scrollDim;
371 }
372 }
373};
374
375

Callers 1

window.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected