", sImg.outerWidth(), sImg.outerHeight(), 0, 0)).find(':last'); $mouseTrap.bind('mousemove', this, function (event) { mx = event.pageX; my = event.pageY }); $mouseTrap.bind('mouseleave', this, function (event) { clearTimeout(controlTimer); if (lens) { lens.fadeOut(299) } if ($tint) { $tint.fadeOut(299) } if (softFocus) { softFocus.fadeOut(299) } zoomDiv.fadeOut(300, function () { ctx.fadedOut() }); return false }); $mouseTrap.bind('mouseenter', this, function (event) { mx = event.pageX; my = event.pageY; zw = event.data; if (zoomDiv) { zoomDiv.stop(true, false); zoomDiv.remove() } var xPos = opts.adjustX, yPos = opts.adjustY; var siw = sImg.outerWidth(); var sih = sImg.outerHeight(); var w = opts.zoomWidth; var h = opts.zoomHeight; if (opts.zoomWidth == 'auto') { w = siw } if (opts.zoomHeight == 'auto') { h = sih } var appendTo = jWin.parent(); switch (opts.position) { case'top': yPos -= h; break; case'right': xPos += siw; break; case'bottom': yPos += sih; break; case'left': xPos -= w; break; case'inside': w = siw; h = sih; break; default: appendTo = $('#' + opts.position); if (!appendTo.length) { appendTo = jWin; xPos += siw; yPos += sih } else { w = appendTo.innerWidth(); h = appendTo.innerHeight() } } zoomDiv = appendTo.append(format('