jquery zoom out limit
Verfasst: 11.09.2012, 11:22
Hallo
Ich habe ein script hier:
https://www.todoweb.de/jquery/final.html#zoom
der sieht wie folgt:
oheight = image.small.height;
owidth = image.small.width;
nheight = (oheight * newZoomLevel);
nwidth = (owidth * newZoomLevel);
left = ((oheight - nheight) / 2) + moveLeft;
top = ((owidth - nwidth) / 2) + moveTop;
if(nheight<oheight) {
zoomLimit =1;
}
if(zoomLimit!=1){
$('.zoom img').css('z-index', '10').stop().animate({
'height' : nheight+'px'
, 'width' : nwidth+'px'
, 'left' : left+'px'
, 'top' : top+'px'
}
, 100
);
ich versuche ein limit zu setzen, wenn man zoom out macht aber es klappt nicht, ich komme nicht weiter.
Kann jemand mir helfen?
am besten hier schauen:
https://www.todoweb.de/jquery/final.html
Ich habe ein script hier:
https://www.todoweb.de/jquery/final.html#zoom
der sieht wie folgt:
oheight = image.small.height;
owidth = image.small.width;
nheight = (oheight * newZoomLevel);
nwidth = (owidth * newZoomLevel);
left = ((oheight - nheight) / 2) + moveLeft;
top = ((owidth - nwidth) / 2) + moveTop;
if(nheight<oheight) {
zoomLimit =1;
}
if(zoomLimit!=1){
$('.zoom img').css('z-index', '10').stop().animate({
'height' : nheight+'px'
, 'width' : nwidth+'px'
, 'left' : left+'px'
, 'top' : top+'px'
}
, 100
);
ich versuche ein limit zu setzen, wenn man zoom out macht aber es klappt nicht, ich komme nicht weiter.
Kann jemand mir helfen?
am besten hier schauen:
https://www.todoweb.de/jquery/final.html

