MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / getSize

Function getSize

javascript/webdriver/atoms/inject/dom.js:100–110  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

98 getSize, [element], opt_window);
99
100 function getSize(e) {
101 var rect = bot.dom.getClientRect(e);
102 var height = rect.height;
103 var width = rect.width;
104 if (!bot.userAgent.IE_DOC_PRE10) {
105 // On IE10, getBoundingClientRect returns floating point values.
106 width = Math.floor(width);
107 height = Math.floor(height);
108 }
109 return { 'width': width, 'height': height };
110 }
111};
112
113

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected