|
@@ -41,16 +41,27 @@
|
|
|
set(hotspot[get(hsp_name)].height,%8);
|
|
|
set(hotspot[get(hsp_name)].width,%8);
|
|
|
set(hotspot[get(hsp_name)].crop,'');
|
|
|
- <!-- txtadd(hotspot[get(hsp_name)].onloaded,"add_tooltip_label(get(%1));"); -->
|
|
|
- if(%2 == 2,
|
|
|
- trace('ser_frame::',get(framewidth));
|
|
|
- set(hotspot[get(hsp_name)].url,get(iconUrl));
|
|
|
- set(hotspot[get(hsp_name)].framewidth,get(framewidth));
|
|
|
- set(hotspot[get(hsp_name)].frames,get(frameNumber));
|
|
|
|
|
|
- crop_animation_r_stop(get(hsp_name));
|
|
|
-
|
|
|
- txtadd(hotspot[get(hsp_name)].onloaded,"trace('onloaded::',get(frameNumber),get(framewidth));do_crop_animation(get(framewidth),get(framewidth),get(frameNumber));"););
|
|
|
+ <!-- 默认 -->
|
|
|
+ if(%2 == 0,
|
|
|
+ txtreplace(iconUrl,'.svg','.png');
|
|
|
+ trace('system::',get(iconUrl));
|
|
|
+ set(hotspot[get(hsp_name)].url,get(iconUrl));
|
|
|
+ set(hotspot[get(hsp_name)].frameNumber,60);
|
|
|
+ set(hotspot[get(hsp_name)].duration,1);
|
|
|
+ set(hotspot[get(hsp_name)].frameRate,calc(1.0 / 60));
|
|
|
+ set(hotspot[get(hsp_name)].framewidth,84);
|
|
|
+ <!-- txtadd(hotspot[get(hsp_name)].onloaded,"do_crop_animation(84,84,60);"); -->
|
|
|
+
|
|
|
+ );
|
|
|
+
|
|
|
+ if(%2 == 2,
|
|
|
+ trace('ser_frame::',get(framewidth));
|
|
|
+ set(hotspot[get(hsp_name)].url,get(iconUrl));
|
|
|
+ set(hotspot[get(hsp_name)].framewidth,get(framewidth));
|
|
|
+ set(hotspot[get(hsp_name)].frameNumber,get(frameNumber));
|
|
|
+ crop_animation_r_stop(get(hsp_name));
|
|
|
+
|
|
|
);
|
|
|
|
|
|
<!-- 个性化标签(3) -->
|
|
@@ -65,7 +76,8 @@
|
|
|
set_label_dir(get(hsp_name),get(lineDirection),0);
|
|
|
|
|
|
);
|
|
|
-
|
|
|
+ txtadd(hotspot[get(hsp_name)].onloaded,"do_crop_animation(get(framewidth),get(framewidth),get(frameRate));"););
|
|
|
+ trace('last_add::',hotspot[get(hsp_name)].onloaded);
|
|
|
addhotspot(get(hsp_name));
|
|
|
</action>
|
|
|
|
|
@@ -75,28 +87,38 @@
|
|
|
registerattribute(frames, calc(xframes * yframes));
|
|
|
registerattribute(frame, 0);
|
|
|
registerattribute(animatiedOn, 1);
|
|
|
- registerattribute(frameRate, calc(1.0 / %3));
|
|
|
+ registerattribute(frameRate, %3);
|
|
|
+ trace('imagewidth::',imagewidth,'::imageheight::',imageheight);
|
|
|
set(crop, '0|0|%1|%2');
|
|
|
clearinterval(calc('crop_anim_' + name));
|
|
|
+ if(%3 == '' OR frameRate == 0 OR isNaN(frameRate),
|
|
|
+ set(frameRate,calc(1.0 / 60));
|
|
|
+ trace('没有frameRate',get(calc(1.0 / 60)));
|
|
|
+ trace('没有frameRate-1',get(frameRate));
|
|
|
+ );
|
|
|
+ trace('params::1::',%1,'::2::',%2,'::3::',%3,':frameRate:',get(frameRate));
|
|
|
+ trace('xframes1::',get(xframes),'::yframes1::',get(yframes));
|
|
|
+
|
|
|
+
|
|
|
if(frameRate GE 0,
|
|
|
setinterval(
|
|
|
calc('crop_anim_' + name),
|
|
|
get(frameRate),
|
|
|
if(loaded,
|
|
|
inc(frame);
|
|
|
+ <!-- trace('frame::',get(frame),'xframes2::',get(xframes),'::yframes2::',get(yframes)); -->
|
|
|
if(frame GE frames, if(onlastframe !== null, onlastframe() ); set(frame,0); );
|
|
|
mod(xpos,frame, xframes);
|
|
|
div(ypos, frame, xframes);
|
|
|
- <!-- trace('onging::',get(frames)); -->
|
|
|
Math.floor(ypos);
|
|
|
mul(xpos, %1);
|
|
|
mul(ypos, %2);
|
|
|
calc(crop, xpos +'|' + ypos + '|%1|%2');
|
|
|
-
|
|
|
+
|
|
|
if(animatiedOn == 0,
|
|
|
- clearinterval(calc('crop_anim_' + name));
|
|
|
- );
|
|
|
-,
|
|
|
+ calc(stopAniCrop,'0|0|'+imagewidth+'|'+imageheight +'|');
|
|
|
+ set(crop, stopAniCrop);
|
|
|
+ );,
|
|
|
clearinterval(calc('crop_anim_' + name));
|
|
|
);
|
|
|
);
|
|
@@ -400,6 +422,7 @@
|
|
|
txtadd(hsLabel, 'tooltip_', %1);
|
|
|
txtadd(hsDot, 'tooldot_', %1);
|
|
|
set(hotspot[get(hsp_name)].hotspottype,%2);
|
|
|
+ set(hotspot[get(hsp_name)].keep,true);
|
|
|
set(hotspot[get(hsp_name)].hotspottitle,%3);
|
|
|
set(hotspot[get(hsp_name)].hotlink,%7);
|
|
|
set(hotspot[get(hsp_name)].hotspotStyle,%10);
|
|
@@ -413,9 +436,10 @@
|
|
|
copy(layer[get(hsLabel)].html, labelCode);
|
|
|
copy(layer[get(hsLabel)].pos, pos);
|
|
|
trace('editJQHotspot',%1,'::type::',%3);
|
|
|
+
|
|
|
if(get(hsp_type) == 3,
|
|
|
trace('edit3::',get(hsp_name));
|
|
|
-
|
|
|
+ set(hotspot[get(hsp_name)].animatiedOn,0);
|
|
|
copy(hotspot[get(hsp_name)].rotate,0);
|
|
|
copy(layer[get(hsLabel)].rotate,0);
|
|
|
|
|
@@ -424,7 +448,6 @@
|
|
|
set(hotspot[get(hsp_name)].width,1);
|
|
|
set(hotspot[get(hsp_name)].height,80);
|
|
|
set(hotspot[get(hsp_name)].padding,0);
|
|
|
- trace('edit3-1::');
|
|
|
|
|
|
txtadd(line,'<div style="background-color: ',get(borderColor),';width:1px;height:80px;"></div>');
|
|
|
<!-- txtadd(dot,'<div style="background-color: ',get(borderColor),';width:10px;height:10px;"></div>'); -->
|
|
@@ -443,45 +466,58 @@
|
|
|
set(hotspot[get(hsp_name)].height,%8);
|
|
|
set(hotspot[get(hsp_name)].width,%8);
|
|
|
|
|
|
- delayedcall(0.1,
|
|
|
- txtadd(tooltipname, 'tooltip_', get(hsp_name));
|
|
|
- set_label_pos(get(tooltipname),get(layer[get(tooltipname)].pos));
|
|
|
- );
|
|
|
- <!-- 序列化类型编辑 -->
|
|
|
- if(get(hsp_type) == 2,
|
|
|
- indexoftxt(index, get(iconUrl), 'image_place_holder.png');
|
|
|
+ delayedcall(0.1,txtadd(tooltipname, 'tooltip_', get(hsp_name)); set_label_pos(get(tooltipname),get(layer[get(tooltipname)].pos)););
|
|
|
+
|
|
|
+ indexoftxt(index, get(iconUrl), 'image_place_holder.png');
|
|
|
|
|
|
if(get(index) GT -1,trace('place-holder');
|
|
|
set(hotspot[get(hsp_name)].animatiedOn,0);
|
|
|
- set(hotspot[get(hsp_name)].crop,'');
|
|
|
- crop_animation_r_stop(get(hsp_name));
|
|
|
+ trace('默认图::');
|
|
|
+ delayedcall(0.2, set(hotspot[get(hsp_name)].crop,'0|0|204|204'););
|
|
|
);
|
|
|
-
|
|
|
- ifnot(get(index) GT -1,
|
|
|
- set(hotspot[get(hsp_name)].animatiedOn,0);
|
|
|
+ ifnot(get(index) GT -1,trace('place-holder');set(hotspot[get(hsp_name)].animatiedOn,1););
|
|
|
+
|
|
|
+ if(get(hsp_type) == 0,
|
|
|
+ txtreplace(iconUrl,'.svg','.png');
|
|
|
+ trace('system::',get(iconUrl));
|
|
|
+ set(hotspot[get(hsp_name)].url,get(iconUrl));
|
|
|
+ set(hotspot[get(hsp_name)].animatiedOn,1);
|
|
|
+ );
|
|
|
+ if(get(hsp_type) == 1,
|
|
|
+ set(hotspot[get(hsp_name)].animatiedOn,0);
|
|
|
+ );
|
|
|
+ <!-- 序列化类型编辑 -->
|
|
|
+ if(get(hsp_type) == 2,
|
|
|
+ <!-- set(hotspot[get(hsp_name)].animatiedOn,1); -->
|
|
|
+ <!-- delayedcall(0.2,set(hotspot[get(hsp_name)].animatiedOn,1);); -->
|
|
|
set(hotspot[get(hsp_name)].visible,true);
|
|
|
- set(hotspot[get(hsp_name)].frames,get(frameNumber));
|
|
|
calc(frameRate, duration / frameNumber);
|
|
|
|
|
|
- set(hotspot[get(hsp_name)].frameRate,get(frameRate));
|
|
|
-
|
|
|
trace('frameRate::',get(frameRate));
|
|
|
trace('frameNumber::',get(frameNumber));
|
|
|
trace('framewidth::',get(framewidth));
|
|
|
trace('duration::',get(duration));
|
|
|
- set(hotspot[get(hsp_name)].xframes,1);
|
|
|
- set(hotspot[get(hsp_name)].yframes,1,get(frameNumber));
|
|
|
- crop_animation_reapply(get(hsp_name),get(frameRate),get(framewidth),get(frameNumber));
|
|
|
- <!-- do_crop_animation(get(hsp_name),get(frameRate),get(frameNumber)); -->
|
|
|
- <!-- do_crop_animation(get(framewidth),get(framewidth),get(frameNumber));"); -->
|
|
|
- );
|
|
|
+
|
|
|
+ if(!isNaN(frameRate) AND frameRate GT 0,set(hotspot[get(hsp_name)].frameRate,get(frameRate)));
|
|
|
+ if(!isNaN(framewidth) AND framewidth GT 0,set(hotspot[get(hsp_name)].framewidth,get(framewidth)));
|
|
|
+ if(!isNaN(frameNumber) AND frameNumber GT 0,set(hotspot[get(hsp_name)].frameNumber,get(frameNumber)));
|
|
|
+
|
|
|
+ <!-- trace('animatiedOn::',get(hotspot[get(hsp_name)].animatiedOn)); -->
|
|
|
+ <!-- set(hotspot[get(hsp_name)].frameNumber,get(frameNumber));
|
|
|
+ set(hotspot[get(hsp_name)].framewidth,get(framewidth)); -->
|
|
|
+
|
|
|
+
|
|
|
+ <!-- set(hotspot[get(hsp_name)].frameRate,get(frameRate)); -->
|
|
|
+ <!-- set(hotspot[get(hsp_name)].xframes,1);
|
|
|
+ set(hotspot[get(hsp_name)].yframes,1,get(frameNumber)); -->
|
|
|
+ <!-- txtreplace(hotspot[get(hsp_name)].onloaded,"do_crop_animation(84,84,60);","do_crop_animation(get(hsp_name),get(frameRate),get(framewidth),get(frameNumber));"); -->
|
|
|
);
|
|
|
|
|
|
set(hotspot[get(hsp_name)].url,get(iconUrl));
|
|
|
set(hotspot[get(hsp_name)].rotate,0);
|
|
|
set(layer[get(hsLabel)].rotate,0);
|
|
|
<!-- set(layer[get(hsDot)].visible,false); -->
|
|
|
-
|
|
|
+ trace('last_edit::',hotspot[get(hsp_name)].onloaded);
|
|
|
);
|
|
|
|
|
|
|