|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 |
<events name="checkhotspots" keep="true" onviewchange="checkhotspots();" /><action name="checkhotspots">
for(set(i,0), i LT hotspot.count, inc(i),
copy(hs,hotspot[get(i)]);
hs.getcenter(hs_h, hs_v);
getlooktodistance(d, hs_h, hs_v);
if(d LT 20,
set(hs.hovering, true);
,
set(hs.hovering, false);
);
); </action>
|
|
|
Source code |
1 2 3 4 5 6 7 8 9 |
<action name="checkhotspots"> for(set(asz,0), asz LT hotspot.count, inc(asz), copy(hs, hotspot[get(asz)]); hs.getcenter(hs_h, hs_v); getlooktodistance(d, hs_h, hs_v); if(d LT 2, set(hs.hovering, true); <!--code for delay --> callwith(hs,onclick); , set(hs.hovering, false); ); ); </action> |
Still doesn't make sense on what you want to do.Finally I managed, but you can enter a time before the click occurs, to allow the user moving not to enter a new pano?
my code
![]()
Source code
1 2 3 4 5 6 7 for(set(asz,0), asz LT hotspot.count, inc(asz), copy(hs, hotspot[get(asz)]); hs.getcenter(hs_h, hs_v); getlooktodistance(d, hs_h, hs_v); if(d LT 2, set(hs.hovering, true); callwith(hs,onclick); , set(hs.hovering, false); ); );
Thx Mau
Still doesn't make sense on what you want to do.