public/ckeditor/4.4dev/core/dom/element.js
function screenPos( element, refWin ) {
				var pos = { x: 0, y: 0 };

				if ( !( element.is( isQuirks ? 'body' : 'html' ) ) ) {
					var box = element.$.getBoundingClientRect();
					pos.x = box.left, pos.y = box.top;
				}

				var win = element.getWindow();
				if ( !win.equals( refWin ) ) {
					var outerPos = screenPos( CKEDITOR.dom.element.get( win.$.frameElement ), refWin );
					pos.x += outerPos.x, pos.y += outerPos.y;
				}

				return pos;
			}
function screenPos( element, refWin ) {
				var pos = { x: 0, y: 0 };

				if ( !( element.is( isQuirks ? 'body' : 'html' ) ) ) {
					var box = element.$.getBoundingClientRect();
					pos.x = box.left, pos.y = box.top;
				}

				var win = element.getWindow();
				if ( !win.equals( refWin ) ) {
					var outerPos = screenPos( CKEDITOR.dom.element.get( win.$.frameElement ), refWin );
					pos.x += outerPos.x, pos.y += outerPos.y;
				}

				return pos;
			}
function screenPos ( element , refWin ) { var pos = { x : 0 , y : 0 } ; if ( ! ( element . is ( isQuirks ? 'body' : 'html' ) ) ) { var box = element . $ . getBoundingClientRect ( ) ; pos . x = box . left , pos . y = box . top ; } var win = element . getWindow ( ) ; if ( ! win . equals ( refWin ) ) { var outerPos = screenPos ( CKEDITOR . dom . element . get ( win . $ . frameElement ) , refWin ) ; pos . x += outerPos . x , pos . y += outerPos . y ; } return pos ; }
Figure out the element position relative to the specified window.
Figure out the element position relative to the specified window .