aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ui/jquery.ui.position.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/jquery.ui.position.js b/ui/jquery.ui.position.js
index aa9881cff..deacedbcc 100644
--- a/ui/jquery.ui.position.js
+++ b/ui/jquery.ui.position.js
@@ -37,7 +37,8 @@ $.fn.position = function( options ) {
targetWidth = target.width();
targetHeight = target.height();
basePosition = { top: 0, left: 0 };
- } else if ( targetElem.scrollTo && targetElem.document ) {
+ // TODO: use $.isWindow() in 1.9
+ } else if ( targetElem.setTimeout ) {
targetWidth = target.width();
targetHeight = target.height();
basePosition = { top: target.scrollTop(), left: target.scrollLeft() };