Skip to content

Commit

Permalink
Correction in docScroll (#360)
Browse files Browse the repository at this point in the history
Variable "node" leverages doc given by window instead of the one given as a parameter. Noticed when putting a popup into an iframe where the content of the iframe has quite some height.
(cherry picked from commit 88c915f)
  • Loading branch information
jojow950i authored and dylans committed Sep 4, 2019
1 parent 1923612 commit 7124d7c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dom-geometry.js
Expand Up @@ -425,7 +425,7 @@ define(["./sniff", "./_base/window","./dom", "./dom-style"],
// returns: Object

doc = doc || win.doc;
var node = win.doc.parentWindow || win.doc.defaultView; // use UI window, not dojo.global window. TODO: use dojo/window::get() except for circular dependency problem
var node = doc.parentWindow || doc.defaultView; // use UI window, not dojo.global window. TODO: use dojo/window::get() except for circular dependency problem
return "pageXOffset" in node ? {x: node.pageXOffset, y: node.pageYOffset } :
(node = has("quirks") ? win.body(doc) : doc.documentElement) &&
{x: geom.fixIeBiDiScrollLeft(node.scrollLeft || 0, doc), y: node.scrollTop || 0 };
Expand Down

0 comments on commit 7124d7c

Please sign in to comment.