以下是 iPresenter焦点图3D图片切换插件轮播滚动特效代码 的示例演示效果:
部分效果截图:
HTML代码(index.html):
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<meta name="keywords" content="JS代码,焦点图,JS广告代码,JS特效代码" />
<meta name="description" content="此代码内容为iPresenter焦点图3D图片切换插件" />
<title>iPresenter焦点图3D图片切换插件</title>
<!--<link rel="stylesheet" href="http://fonts.useso.com/css?family=PT+Sans+Narrow" />-->
<link rel="stylesheet" href="css/styles.css" />
<link rel="stylesheet" href="css/demo1.css" />
<!-- JavaScript includes -->
<script src="js/jquery.min.js"></script>
<script src="js/ipresenter.packed.js"></script>
<script>
$(document).ready(function(){
$('#ipresenter').iPresenter({
timerPadding: -1,
controlNav: true,
controlNavThumbs: true,
controlNavNextPrev: false
});
});
</script>
</head>
<body>
<!-- 代码 开始 -->
<div class="container">
<div id="ipresenter">
<div id="intro" class="step" data-x="0" data-y="0" data-thumbnail="images/thumbnails/1.jpg">
<img src="images/details.png" />
<h2>A phone that sees the world like you do, in 3D</h2>
<p>
Now your photos can have as much depth as the moment itself. HTC EVO 3D captures your photos and videos in 3D, plus you can view them without the glasses. The stunning 4.3-inch qHD display gives you crisp websites, vivid images and incredibly fluid videos.
</p>
</div>
<div id="capture" class="step" data-x="1100" data-y="1200" data-scale="1.8" data-rotate="180" data-thumbnail="images/thumbnails/2.jpg">
<img src="images/ksp1.png" />
<h2>Capture life in 3D</h2>
<p>
HTC EVO 3D allows you to shoot 3D movies and snap 3D photos via dual cameras, so no matter where you are, capture life as it should be. And see it all in true-to-life detail without 3D glasses. from:www.larentuku.com
</p>
</div>
<div id="view" class="step" data-x="-300" data-y="600" data-scale="0.2" data-rotate="270" data-thumbnail="images/thumbnails/3.jpg">
<img src="images/ksp2.png" />
<h2>An incredible view</h2>
<p>
The large 4.3 inch display serves up incredibly crisp websites, vivid images and fluid video on a pixel-packed qHD screen. Catch the latest blockbusters straight from HTC Watch ?a new service that starts the show just seconds into the download and monitors your Internet connection to ensure uninterrupted viewing.
</p>
</div>
</div>
</div>
</body>
</html>
JS代码(ipresenter.packed.js):
/** * jQuery-Plugin "iPresenter" * * @version:2.0,24.05.2012 * @version:1.1,19.04.2012 * @version:1.0,21.03.2012 * * @author:Hemn Chawroka * http://www.iprodev.com/ * */
var b=['(5(b){
b.4a.47=5(a){
18 a=2L.46({
1X:"1z-1U-27",2J:!0,45:!0,1F:2F,2r:6j,42:!0,2Z:0.6,1n:!1,2H:!0,2I:0.6,41:!1,3Y:!0,3X:!0,3W:!0,3V:!1,2m:0.4,2l:"5T",2j:"5S",3T:"5O",3S:"5J",3P:!1,1t:1,1j:"5G",28:"#5F",2f:"#3O",2c:0.2,1b:35,1J:4,1E:3,3N:1,3M:"#3O",3L:"5w",2W:4,3K:"1M-1N",3H:5(){
}
,3G:5(){
}
,36:5(){
}
,3E:5(){
}
,3D:5(){
}
,5c:5(){
}
,3C:5(){
}
}
,a),l=b(16),d=b(l[0].58),g=b(".3B",l);
55(d[0]);
18 m=g.3z,j=[],o=1C,q=!1,n=1,P=d.1B(),Q=d.2i(),h="1z-1U-27",t=!1,R={
1I:a.2f,2G:1f(a.1E),1O:1f(a.1b),1P:1f(a.1b-2*a.1J-a.1E)}
,S={
1I:a.28,2G:1f(a.1E+2*a.1J),1O:1f(a.1b),1P:1f(a.1b-(a.1E+2*a.1J))}
,T={
1I:a.28,1O:1f(a.1b),1P:1f(a.1b-1)}
,U={
1I:a.2f,1O:1f(a.1b),1P:1f(a.1b-2*a.1J-1)}
,B=a.2r,i=0;
b("2T",l).2n(5(){
18 a=b(16);
j.2V(a.22("2Y"));
a.17("1L")&&j.2V(a.17("1L"))}
);
g.2n(5(){
b(16).17("1L")&&j.2V(b(16).17("1L"))}
);
a.1t=a.3P?1x.4R(1x.4Q()*m):a.1t;
a.1t=0<a.1t&&a.1t>=m?m:a.1t;
18 n=a.1t,B=g.1w(n-1).17("2g")?g.1w(n-1).17("2g"):a.2r,G=5(){
2B(18 a=["4O","4M","4L","4K","4J"],b=0,e=!1,d=3s.4H("4G");
a[b];
){
1v(a[b]1U d.1h){
e=!0;
9}
b++}
1s e}
,u=5(a){
1s G()?" 4F("+a.x+"1g,"+a.y+"1g,"+a.z+"1g) ":" 1c("+a.x+"1g,"+a.y+"1g) "}
,v=5(a,b){
18 e=" 4E("+a.x+"2a) ",d=" 4D("+a.y+"2a) ",c=" 4C("+a.z+"2a) ";
1s G()?b?c+d+e:e+d+c:" 1i("+a.z+"2a) "}
,w=5(a){
1s" 1r("+a+") "}
,H=5(a){
1s{
1c:{
x:a.17("x")||0,y:a.17("y")||0,z:a.17("z")||0}
,1i:{
x:a.17("4B")||0,y:a.17("4A")||0,z:a.17("4z")||a.17("1i")||0}
,1r:a.17("1r")||1}
}
,C=5(a){
a=b.3r(a);
3q(a){
7"4w":a="11-Y(0.25,0.25,0.3p,0.3p)";
9;
7"1z":a="11-Y(0.25,0.2p,0.25,1.12)";
9;
7"1z-1U":a="11-Y(0.2P,0.12,1.12,1.12)";
9;
7"1z-27":a="11-Y(0.12,0.12,0.2Q,1.12)";
9;
7"1z-1U-27":a="11-Y(0.2P,0.12,0.2Q,1.12)";
9;
7"1z-27-1U":a="11-Y(0.12,0.2P,1.12,0.2Q)";
9;
7"4u":a="11-Y(0.2S,0.4t,0.3o,0.4r)";
9;
7"4p":a="11-Y(0.2S,0.4o,0.4l,0.3n)";
9;
7"6q":a="11-Y(0.6p,0.3j,0.6l,0.3i)";
9;
7"51":a="11-Y(0.5U,0.32,0.4T,0.6u)";
9;
7"4I":a="11-Y(0.4Z,0.12,0.52,0.59)";
9;
7"5z":a="11-Y(0.3F,0.32,0.6k,0.6o)";
9;
7"6t":a="11-Y(0.3a,0.4g,0.4h,0.4s)";
9;
7"4v":a="11-Y(0.3a,-0.4x,0.4y,0.3b)";
9;
7"4N":a="11-Y(0.25,0.4P,0.4S,0.4U)";
9;
7"4V":a="11-Y(0.4W,0.4Y,0.3c,1.12)";
9;
7"6D":a="11-Y(0.3e,0.53,0.54,1.12)";
9;
7"56":a="11-Y(0.57,1.12,0.3f,1.12)";
9;
7"5d":a="11-Y(0.5e,0.5f,0.5g,1.12)";
9;
7"5j":a="11-Y(0.3n,1.12,0.3i,1.12)";
9;
7"5o":a="11-Y(0.5p,0.5s,0.3e,1.12)";
9;
7"5v":a="11-Y(0.3g,0.5A,0.3f,1.5B)";
9;
7"5C":a="11-Y(0.5D,0.3j,0.5E,0.5I)";
9;
7"5K":a="11-Y(0.5M,0.3b,0.3c,1.12)";
9;
7"5N":a="11-Y(0.5P,0.12,0.3g,1.12)";
9;
7"5Q":a="11-Y(0.3h,0.12,0.5V,1.12)";
9;
7"5Y":a="11-Y(0.5Z,0.32,0.2S,0.3F)";
9;
7"62":a="11-Y(1.12,0.12,0.12,1.12)";
9;
7"64":a="11-Y(0.65,0.66,0.67,0.3h)";
9;
7"68":a="11-Y(0.3o,0,0.6i,1)"}
1s a}
,I=5(a,b,e){
18 d=-2w*1x.2v/1W,b=(b-2w)*1x.2v/1W,c=1x.2X(e.1O/2);
a.3k();
a.3l(c,c,e.1P/2,d,b,!1);
a.6v=e.2G;
a.6w=e.1I;
a.6A="2X";
a.4f();
a.3m()}
,J=5(a,b,e){
18 d=-2w*1x.2v/1W,b=(b-2w)*1x.2v/1W,c=1x.2X(e.1O/2);
a.3k();
a.4i(c,c);
a.3l(c,c,e.1P/2,d,b,!1);
a.4j=e.1I;
a.4k();
a.3m()}
,D=5(b){
b&&b.4m(0,0,a.1b,a.1b);
"4n"==a.1j.1H()?(I(b,26,S),I(b,i,R)):"4q"==a.1j.1H()?(J(b,26,T),J(b,i,U)):K.14({
1B:2p*(i/26)+"%"}
);
i+=2}
,h=C(a.1X),L={
2R:"2N","-1e-Z-23":"0% 0%","-1e-8":"1V 21 "+h,"-1e-Z-1h":"1p-3d","-1e-1q":"1Y","-1d-Z-23":"0% 0%","-1d-8":"1V 21 "+h,"-1d-Z-1h":"1p-3d","-1d-1q":"1Y","-o-Z-23":"0% 0%","-o-8":"1V 21 "+h,"-o-Z-1h":"1p-3d","-o-1q":"1Y","-19-Z-23":"0% 0%","-19-8":"1V 21 "+h,"-19-Z-1h":"1p-3d","-19-1q":"1Y","Z-23":"0% 0%",8:"1V 21 "+h,"Z-1h":"1p-3d",1q:"1Y",1M:"50%",1G:"50%"}
;
l.29(\'<15 1R="3t"></15><15 1R="2C"><15></15></15>\');
d.29(\'<3u 1R="13-1j" 1B="\'+a.1b+\'" 2i="\'+a.1b+\'"><15></15></3u>\');
a.42&&d.29("<a 1u=\'1A\' 1S=\'"+a.2l+"\' 1R=\'3v\'></a><a 1u=\'1A\' 1S=\'"+a.2j+"\' 1R=\'3w\'></a>");
1v(a.1n){
18 c=\'<15 1u="13-1n">\';
a.2H&&(c+=\'<a 1u="13-3x" 1S="\'+a.2j+\'">\'+a.2j+"</a>");
2B(18 c=c+\'<15 1u="13-4X"><3y>\',f=0;
f<m;
f++){
18 p=g.1w(f);
a.41?(p=p.17("1L"),c+=\'<2k><a 1u="13-1Q" 2O="\'+(f+1)+\'"><2T 2Y="\'+p+\'" /></a></2k>\'):(p=p.17("1L"),c+=\'<2k><a 1u="13-1Q" 2O="\'+(f+1)+\'">\'+(f+1)+"</a>",a.3Y&&(c+=\'<15 1u="13-2M"><15><2T 2Y="\'+p+\'" /></15></15>\'),c+="</2k>")}
c+="</3y></15>";
a.2H&&(c+=\'<a 1u="13-3A" 1S="\'+a.2l+\'">\'+a.2l+"</a>");
d.29(c+"</15>");
b(".13-1n a.13-1Q:1w("+(n-1)+")",d).1Z("1D")}
"2E"==a.1j.1H()&&b("#13-1j").5a(\'<15 1R="13-1j">\'+b("#13-1j").5b()+"</15>");
18 E=b("#3t",l),V=b("#2C",l),M=b("#2C 15",l),k=b("#13-1j",d),K=b("15",k);
2s="2E"!=a.1j.1H()?k[0].5h("2d"):1C;
g.5i(E);
b("a.1A").2z();
k.14({
5k:"5l","z-5m":"5n",2R:"2N",1a:a.2c}
).2z();
"2E"==a.1j.1H()&&(k.14({
1a:a.2c,3I:a.2W+"1g",1B:a.1b,2i:a.1E,5q:a.3N+"1g "+a.3M+" "+a.3L,5r:a.1J,3J:a.28}
),K.14({
3I:a.2W-1+"1g",1B:0,2i:a.1E,3J:a.2f,"5t":"1G"}
));
c=a.3K.1H().5u("-");
2B(f=0;
f<c.3z;
f++)"1M"==c[f]&&k.14({
1M:"2t",2u:""}
),"5x"==c[f]&&k.14({
1M:Q/2-a.1b/2+"1g",2u:""}
),"2u"==c[f]&&k.14({
2u:"2t",1M:""}
),"1G"==c[f]&&k.14({
1G:"2t",1N:""}
),"5y"==c[f]&&k.14({
1G:P/2-a.1b/2+"1g",1N:""}
),"1N"==c[f]&&k.14({
1N:"2t",1G:""}
);
l.14(L);
E.14(L);
g.2n(5(d){
18 c=b(16),e=H(c),e={
2R:"2N","-1e-Z":"1c(-50%,-50%)"+u(e.1c)+v(e.1i)+w(e.1r)+"","-1e-Z-1h":"1p-3d","-1d-Z":"1c(-50%,-50%)"+u(e.1c)+v(e.1i)+w(e.1r)+"","-1d-Z-1h":"1p-3d","-o-Z":"1c(-50%,-50%)"+u(e.1c)+v(e.1i)+w(e.1r)+"","-o-Z-1h":"1p-3d","-19-Z":"1c(-50%,-50%)"+u(e.1c)+v(e.1i)+w(e.1r)+"","-19-Z-1h":"1p-3d",Z:"1c(-50%,-50%)"+u(e.1c)+v(e.1i)+w(e.1r)+"","Z-1h":"1p-3d",1a:a.2m}
;
c.14(e).22("3B",d+1);
d==0&&c.14({
1a:1}
)}
).2z();
18 W=5(){
t=20;
k.1k({
1a:a.2c}
);
B=g.1w(n-1).17("2g")?g.1w(n-1).17("2g"):a.2r;
o==1C&&q&&F();
a.3D.1y(16)}
,x=5(c,o){
t=2b;
b(".13-1n a.13-1Q",d).2e("1D").1w(c-1).1Z("1D");
a.3E.1y(16);
k.1k({
1a:0}
,5(){
D(2s)}
);
18 e=g.1w(c-1),f=H(e),m=e.31("1D");
h=e.17("1X")?C(b.3r(e.17("1X"))):C(a.1X);
g.2e("1D");
e.1Z("1D");
18 j={
x:-1f(f.1i.x,10),y:-1f(f.1i.y,10),z:-1f(f.1i.z,10)}
,q={
x:-f.1c.x,y:-f.1c.y,z:-f.1c.z}
,i=1/5H(f.1r),s=i>=1,r=!m&&!o?a.1F/2F+"s":"0",p=s?a.1F/2+"19":"3Q",s=s?"3Q":a.1F/2+"19",f=f.1r*2F+"1g",i=w(i),j=v(j,2b)+u(q);
!m&&t&&5L(W,a.1F);
1v(o){
g.14({
1a:a.2m}
);
e.14({
1a:1}
)}
3R{
g.1k({
1a:a.2m}
,a.1F/2);
e.1k({
1a:1}
,a.1F/1.3)}
l.14({
"-1e-1q":f,"-1e-Z":i,"-1e-8-1l":r,"-1e-8-1m":p,"-1e-8-1o-5":h,"-1d-1q":f,"-1d-Z":i,"-1d-8-1l":r,"-1d-8-1m":p,"-1d-8-1o-5":h,"-o-1q":f,"-o-Z":i,"-o-8-1l":r,"-o-8-1m":p,"-o-8-1o-5":h,"-19-1q":f,"-19-Z":i,"-19-8-1l":r,"-19-8-1m":p,"-19-8-1o-5":h,1q:f,Z:i,"8-1l":r,"8-1m":p,"8-1o-5":h}
);
E.14({
"-1e-Z":j,"-1e-8-1l":r,"-1e-8-1m":s,"-1e-8-1o-5":h,"-1d-Z":j,"-1d-8-1l":r,"-1d-8-1m":s,"-1d-8-1o-5":h,"-o-Z":j,"-o-8-1l":r,"-o-8-1m":s,"-o-8-1o-5":h,"-19-Z":j,"-19-8-1l":r,"-19-8-1m":s,"-19-8-1o-5":h,Z:j,"8-1l":r,"8-1m":s,"8-1o-5":h}
);
n=c}
,X=5(){
D(2s);
1v(i>26){
z();
y()}
}
,F=5(){
o=5R(X,B/1W)}
,z=5(){
2D(o);
o=1C;
i=0}
,N=5(){
q=2b;
F();
k.2e("3U").1Z("2U").22("1S",a.3S);
k.14("5W","5X");
D(2s);
a.3H.1y(16)}
,O=5(){
q=20;
2D(o);
o=1C;
k.2e("2U").1Z("3U").22("1S",a.3T);
a.3G.1y(16)}
,y=5(){
1v(t)1s 20;
1v(n==m){
x(1);
a.45||O();
a.3C.1y(16)}
3R x(n+1);
q&&z()}
,A=5(){
1v(t)1s 20;
n==1?x(m):x(n-1);
q&&z()}
;
60 61(j,5(a){
a=a*10;
M.1K().1k({
1B:a+"%"}
)}
,5(){
M.1K().1k({
1B:"2p%"}
,5(){
V.63();
g.3Z();
b("a.1A").3Z();
m>0&&a.2J&&N();
a.1t>1&&x(n,2b);
a.36.1y(16)}
)}
);
a.3V&&d.2o(5(){
1v(q){
2D(o);
o=1C}
}
,5(){
o==1C&&(q&&i<26&&a.2J&&!t)&&F()}
);
b("a#3v",d).1T(y);
b("a#3w",d).1T(A);
b("a.13-3x",d).1T(A);
b("a.13-3A",d).1T(y);
b(".13-1n a.13-1Q",d).1T(5(){
1v(t||b(16).31("1D"))1s 20;
n=1f(b(16).22("2O"));
x(n);
q&&z()}
);
k.1T(5(){
b(16).31("2U")?O():N()}
);
b(".1A",d).14({
1a:a.2Z}
);
d.2o(5(){
b(".1A",d).1K().1k({
1a:1}
,2q)}
,5(){
b(".1A",d).1K().1k({
1a:a.2Z}
,2q)}
);
b(".13-1n",d).14({
1a:a.2I}
);
d.2o(5(){
b(".13-1n",d).1K().1k({
1a:1}
,2q)}
,5(){
b(".13-1n",d).1K().1k({
1a:a.2I}
,2q)}
);
b(".13-1n a.13-1Q",d).2o(5(){
b(".13-2M",b(16).43()).69()}
,5(){
b(".13-2M",b(16).43()).6a()}
);
a.3W&&6b.6c.6d(/6e|6f|6g|6h/i)&&d.44({
2K:y,2y:A}
);
a.3X&&b(3s).2x("6m.47",5(a){
3q(a.6n){
7 33:7 37:7 38:A();
9;
7 34:7 39:7 40:y()}
}
)}
;
b.4a.44=5(a){
a=2L.46({
24:{
x:30,y:2p}
,2K:5(){
48("49 1G")}
,2y:5(){
48("49 1N")}
}
,a);
b(16).2n(5(){
18 l=b(16),d=0,g=0,m=0,j=0;
l.2x("6r 6s",5(a){
d=a.2h.4b[0].4c;
g=a.2h.4b[0].4d;
m=d;
j=g}
);
l.2x("6x 6y",5(a){
a.6z();
m=a.2h.4e[0].4c;
j=a.2h.4e[0].4d}
);
l.2x("6B 6C",5(){
18 b=g-j;
b<a.24.y&&b>-1*a.24.y&&(2A=d-m,2A>a.24.x&&a.2K.1y(16),2A<-1*a.24.x&&a.2y.1y(16))}
)}
)}
}
)(2L);
',"|","split","|||||function||case|transition|break|||||||||||||||||||||||||||||||||||||||||||||||||||bezier|transform||cubic|000|ipresenter|css|div|this|data|var|ms|opacity|timerDiameter|translate|moz|webkit|parseInt|px|style|rotate|timer|animate|duration|delay|controlNav|timing|preserve|perspective|scale|return|startStep|class|if|eq|Math|call|ease|ipresenter_stepsNav|width|null|active|timerStroke|animSpeed|left|toLowerCase|color|timerPadding|stop|thumbnail|top|right|diameter|radius|control|id|title|click|in|all|180|easing|1000px|addClass|false|0s|attr|origin|threshold|250|360|out|timerBg|append|deg|true|timerOpacity||removeClass|timerColor|pausetime|originalEvent|height|previousLabel|li|nextLabel|itemsOpacity|each|hover|100|300|pauseTime|ctx|10px|bottom|PI|90|bind|swipeRight|hide|changeX|for|preloader|clearInterval|bar|1E3|size|controlNavNextPrev|controlNavHoverOpacity|autoPlay|swipeLeft|jQuery|tooltip|absolute|rel|420|580|position|550|img|play|push|timerBarStrokeRadius|round|src|directionNavHoverOpacity||hasClass|050||||onAfterLoad||||600|045|355||165|320|175|860|220|030|beginPath|arc|closePath|190|680|750|switch|trim|document|content|canvas|ipresenter_nextStep|ipresenter_prevStep|controlPrevNav|ul|length|controlNextNav|step|onLastStep|onAfterChange|onBeforeChange|950|onPause|onPlay|borderRadius|background|timerPosition|timerBarStrokeStyle|timerBarStrokeColor|timerBarStroke|FFF|randomStart|0ms|else|pauseLabel|playLabel|pause|pauseOnHover|touchNav|keyboardNav|controlNavTooltip|show||controlNavThumbs|directionNav|parent|swipe|replay|extend|iPresenter|alert|swiped|fn|targetTouches|pageX|pageY|touches|stroke|040|980|moveTo|fillStyle|fill|675|clearRect|360bar|055|easeInCubic|pie|530|335|085|easeInQuad|easeInBack|linear|280|735|rotatez|rotatey|rotatex|rotateZ|rotateY|rotateX|translate3d|form|createElement|easeInSine|msPerspective|OPerspective|MozPerspective|WebkitPerspective|easeOutQuad|perspectiveProperty|460|random|floor|450|855|940|easeOutCubic|215|items|610|470||easeInQuint|745|840|440|disableSelection|easeOutQuint|230|parentNode|715|replaceWith|html|onSlideshowEnd|easeOutSine|390|575|565|getContext|appendTo|easeOutExpo|cursor|pointer|index|1000|easeOutCirc|075|border|padding|820|float|split|easeOutBack|solid|middle|center|easeInExpo|885|275|easeInOutQuad|455|515|333|Pie|parseFloat|955|Pause|easeInOutCubic|setTimeout|645|easeInOutQuart|Play|770|easeInOutQuint|setInterval|Previous|Next|755|070|display|block|easeInOutSine|445|new|ImagePreload|easeInOutExpo|remove|easeInOutCirc|785|135|150|easeInOutBack|fadeIn|fadeOut|navigator|userAgent|match|ipad|iphone|ipod|android|265|5E3|795|685|keyup|keyCode|035|895|easeInQuart|touchstart|MozTouchDown|easeInCirc|060|lineWidth|strokeStyle|touchmove|MozTouchMove|preventDefault|lineCap|touchend|MozTouchRelease|easeOutQuart","","fromCharCode","replace","\\w+","\\b","g"];
eval(function(e,f,a,d,c,g){
c=function(a){
return(a<f?b[4]:c(parseInt(a/f)))+(35<(a%=f)?String[b[5]](a+29):a.toString(36))}
;
if(!b[4][b[6]](/^/,String)){
for(;
a--;
)g[c(a)]=d[a]||c(a);
d=[function(a){
return g[a]}
];
c=function(){
return b[7]}
;
a=1}
for(;
a--;
)d[a]&&(e=e[b[6]](RegExp(b[8]+c(a)+b[8],b[9]),d[a]));
return e}
(b[0],62,412,b[3][b[2]](b[1]),0,{
}
));
function ImagePreload(b,a,l){
this.m_pfnPercent=a;
this.m_pfnFinished=l;
this.m_nProcessed=this.m_nLoaded=0;
this.m_aImages=[];
this.m_nICount=b.length;
for(a=0;
a<b.length;
a++)this.Preload(b[a])}
ImagePreload.prototype.Preload=function(b){
var a=new Image;
this.m_aImages.push(a);
a.onload=ImagePreload.prototype.OnLoad;
a.onerror=ImagePreload.prototype.OnError;
a.onabort=ImagePreload.prototype.OnAbort;
a.oImagePreload=this;
a.bLoaded=!1;
a.source=b;
a.src=b}
;
ImagePreload.prototype.OnComplete=function(){
this.m_nProcessed++;
this.m_nProcessed==this.m_nICount?this.m_pfnFinished():this.m_pfnPercent(Math.round(10*(this.m_nProcessed/this.m_nICount)))}
;
ImagePreload.prototype.OnLoad=function(){
this.bLoaded=!0;
this.oImagePreload.m_nLoaded++;
this.oImagePreload.OnComplete()}
;
ImagePreload.prototype.OnError=function(){
this.bError=!0;
this.oImagePreload.OnComplete()}
;
ImagePreload.prototype.OnAbort=function(){
this.bAbort=!0;
this.oImagePreload.OnComplete()}
;
function disableSelection(b){
"undefined"!=typeof b.style.MozUserSelect?b.style.MozUserSelect="none":"undefined"!=typeof b.onselectstart?b.onselectstart=function(){
return!1}
:b.onmousedown=function(){
return!1}
;
b.style.cursor="default"}
;
CSS代码(demo1.css):
div.container{position:relative;height:600px;width:1258px;overflow:hidden;box-shadow:inset 0px 0px 15px rgba(200,200,200,1);margin:auto;margin-top:10px;border:#DDD 1px solid;border-radius:5px;}
div#ipresenter div#preloader{position:absolute;display:block;width:150px;height:5px;z-index:200;border:#CCC 1px solid;border-radius:4px;padding:1px;background:#FFF;-webkit-transform:translate(-75px,0px);-moz-transform:translate(-75px,0px);-o-transform:translate(-75px,0px);-ms-transform:translate(-75px,0px);transform:translate(-75px,0px);box-shadow:0px 0px 8px rgba(200,200,200,1);}
div#ipresenter div#preloader div{display:block;width:0%;height:5px;background:#CCC;border-radius:3px;}
div#ipresenter div.step{max-width:800px;min-width:600px;text-align:center;z-index:10;}
div#ipresenter div.step h2,div.step p{text-align:left;}
div#ipresenter div#intro{width:800px;}
div#ipresenter div#intro img{float:left;}
div#ipresenter div#capture h2{text-align:center}
a.ipresenter_stepsNav{display:block;cursor:pointer;position:absolute;width:40px;height:100px;background-image:url(../images/nav_paddles.png);top:43%;-webkit-transition:opacity 150ms ease-out;-moz-transition:opacity 150ms ease-out;-o-transition:opacity 150ms ease-out;transition:opacity 150ms ease-out;}
a.ipresenter_stepsNav:active{background-image:url(../images/nav_paddles_down.png);}
a#ipresenter_nextStep{right:20px;background-position:56px 0px;}
a#ipresenter_prevStep{left:20px;background-position:-16px 0px}
div.container div.ipresenter-controlNav{display:inline-block;position:absolute;left:499px;bottom:20px;}
div.container div.ipresenter-controlNav a{float:left;box-shadow:0px 0px 5px rgba(0,0,0,0.6);margin-left:20px;overflow:hidden;border-radius:3px;height:40px;width:64px;}
div.container div.ipresenter-controlNav div.ipresenter-items ul{list-style:none;}
div.container div.ipresenter-controlNav div.ipresenter-items ul li{float:left;}
CSS代码(styles.css):
*{margin:0px;padding:0px;}
body{font-family:'PT Sans Narrow',Aller;}
h2{font-size:38px}
p{line-height:150%;font-size:13pt;}
a{color:#39f;text-decoration:none;outline:none;cursor:pointer;}
a:hover{color:#C00;text-decoration:none;}
p.copy{display:block;font-size:16px;font-weight:normal;color:#999;margin-top:10px;}
ul.examples{list-style:none;display:block;width:1258px;height:28px;margin:10px auto 0px auto;}
ul.examples li.logo{float:left;font-size:24px;text-shadow:#BBB 1px 1px 3px;}
ul.examples li{float:right;}
ul.examples li a{float:right;padding:5px 12px;border:1px solid #3079ED !important;background:#4B8DF8;background:-webkit-linear-gradient(top,#4C8FFD,#4787ED);background:-moz-linear-gradient(top,#4C8FFD,#4787ED);background:-ms-linear-gradient(top,#4C8FFD,#4787ED);background:-o-linear-gradient(top,#4C8FFD,#4787ED);color:#FFF !important;text-shadow:0 1px 0 #2F5BB7 !important;text-decoration:none;font-size:13px;margin-left:10px;border-radius:3px;}
ul.examples li a:hover{border:1px solid #2F5BB7 !important;background:#3F83F1;background:-webkit-linear-gradient(top,#4D90FE,#357AE8);background:-moz-linear-gradient(top,#4D90FE,#357AE8);background:-ms-linear-gradient(top,#4D90FE,#357AE8);background:-o-linear-gradient(top,#4D90FE,#357AE8);-moz-box-shadow:0 1px 0px #DDD;-webkit-box-shadow:0 1px 0px #DDD;box-shadow:0 1px 0px #DDD;}
ul.examples li a.active{border:1px solid #CCC !important;background:#DDD;background:-webkit-linear-gradient(top,#EEE,#DDD);background:-moz-linear-gradient(top,#EEE,#DDD);background:-ms-linear-gradient(top,#EEE,#DDD);background:-o-linear-gradient(top,#EEE,#DDD);color:#000 !important;text-shadow:0 1px 0 #FFF !important;}