Hallo zusammen, hallo Klaus!
Ich arbeite mich seit zwei knapp zwei Monaten in KRPano ein und bin schwer begeistert!
Zur zeit arbeite ich an einer Tour mit einer Karte (Foto, keine Bing-Map) + Radar-Plugin und einer kleinen Galerie mit den Vorschaubildern. Beide Elemente sind jeweils in einer Scrollarea eingebunden. Nun habe ich folgendes Problem bei dem ich nicht mehr weiterkomme:
Die Aktualisierung des Radars auf der Karte funktioniert wunderbar! Wenn ich aber ein neues Pano über die Galerie öffne, bleibt das Radar beim jeweils letzten Pano.
Hier ist der Code der Karte:
<style name="map-point" url="map-point.png" keep="true" align="lefttop" scale="0.5" />
<layer name="map" keep="true" type="container" align="righttop" width="650" zorder="2" height="400" y="-400" x="0" bgcolor="0x000000" bgalpha="0.4">
<layer name="map-rand-u" keep="true" type="container" align="bottom" width="650" height="5" y="0" x="0" zorder="2" bgcolor="0x000000" bgalpha="1.0" />
<layer name="map-rand-l" keep="true" type="container" align="left" width="5" height="400" y="0" x="0" zorder="2" bgcolor="0x000000" bgalpha="1.0" />
<layer name="scrollarea-karte" url="%SWFPATH%/plugins/scrollarea.swf" alturl="%SWFPATH%/plugins/scrollarea.js" align="center" width="900" height="600" zorder="1" direction="all" onhover_autoscrolling="false" onloaded="setcenter(0,0);">
<!-- karte -->
<layer name="karte" url="karte.png" zorder="3" keep="true" align="top" y="0" x="0" children="true" />
<!-- map spots -->
<layer name="point-wasser-01" style="map-point" zorder="4" edge="center" x="173" y="210" onover="set(scale,1); set(plugin[prev-wasser-01].visible,true); action(prevbox-auf),();" onout="set(scale,0.5); set(plugin[prev-wasser-01].visible,false); action(prevbox-zu),();" onclick="loadpano(wasser-01.xml, null, MERGE, BLEND(1)); set(plugin[radar].x, 173);
set(plugin[radar].y, 210); set(plugin[radar].heading, 80.0); " />
<layer name="point-towerdach" style="map-point" zorder="4" edge="center" x="565" y="455" onover="set(scale,1); set(plugin[prev-towerdach].visible,true); action(prevbox-auf),();" onout="set(scale,0.5); set(plugin[prev-towerdach].visible,false); action(prevbox-zu),();" onclick="loadpano(towerdach.xml, null, MERGE, BLEND(1)); set(plugin[radar].x, 565);
set(plugin[radar].y, 455); set(plugin[radar].heading, 170.0);" />
</layer>
</layer>
<plugin name="radar"
url="%SWFPATH%/plugins/radar.swf"
alturl="%SWFPATH%/plugins/radar.js"
keep="true"
align="lefttop"
edge="center"
parent="karte"
x="173" y="210"
scale="1.0"
heading="80.0"
headingoffset="90.0"
fillcolor="0x3F3F3F"
fillalpha="0.5"
/>
<!-- map oeffnen schliessen -->
<layer name="map-schaltf" url="schaltflaeche-o.png" keep="true" align="righttop" y="0" x="280" >
<layer name="map-zu" url="pfeil_oben.png" align="center" x="0" visible="false" scale="0.7" onover="set(scale,1);" onout="set(scale,0.7);" onclick="action(map-zu,();" />
<layer name="map-auf" url="pfeil_unten.png" align="center" x="0" visible="true" scale="0.7" onover="set(scale,1);" onout="set(scale,0.7);" onclick="action(map-auf,();" />
</layer>
<!-- prevbox -->
<layer name="prevbox" keep="true" type="container" align="righttop" edge="righttop" children="true" width="210" height="110" x="400" y="-115" bgcolor="0x000000" bgalpha="1.0"/>
<!-- prevs -->
<layer name="prev-wasser-01" url="%SWFPATH%/thumbs/wasser-01_thumb.jpg" align="center" edge="center" x="" y="" parent="prevbox" keep="true" enabled="false" visible="false" />
<layer name="prev-towerdach" url="%SWFPATH%/thumbs/towerdach_thumb.jpg" align="center" edge="center" x="" y="" parent="prevbox" keep="true" enabled="false" visible="false" />
<!-- map oeffnen schliessen -->
<action name="map-zu">
tween(plugin[map].y,-400,0.5);
tween(plugin[prevbox].y,-125,0.5);
tween(plugin[map-schaltf].y,0,0.5);
set(plugin[map-auf].visible,true);
set(plugin[map-zu].visible,false);
</action>
<action name="map-auf">
tween(plugin[map].y,0,0.5);
tween(plugin[prevbox].y,290,0.5);
tween(plugin[map-schaltf].y,400,0.5);
set(plugin[map-auf].visible,false);
set(plugin[map-zu].visible,true);
</action>
<action name="prevbox-auf">
tween(plugin[prevbox].y,395,0.5);
</action>
<action name="prevbox-zu">
tween(plugin[prevbox].y,290,0.5);
</action>
Display More
Hier der Code der Galerie (mit nur einem Beipielbild):
<!-- adjust the examples backbutton position (if available), the wait(0) in the onstart action allows executing this event -->
<events name="backbutton_adjust" keep="true" onxmlcomplete="if(layer[backbutton], set(layer[backbutton].y,106));" />
<progress showload="none" showwait="none" />
<layer name="thumbs" keep="true" type="container" align="left" width="230" height="100%" y="0" x="-5" bgcolor="0x000000" bgalpha="1.0">
<!-- scroll buttons - call the scrollarea scrollby() action as long as pressing down the button -->
<layer name="arrow_oben" url="arrow2_oben.png" align="top" y="3" scale="0.5" zorder="3" alpha="0.6" onover="tween(alpha,1);" onout="tween(alpha,0.6);" ondown="onover(); asyncloop(pressed, layer[scrollarea].scrollby(0,1));" onup="onout();" />
<layer name="arrow_unten" url="arrow2_unten.png" align="bottom" y="3" scale="0.5" zorder="3" alpha="0.6" onover="tween(alpha,1);" onout="tween(alpha,0.6);" ondown="onover(); asyncloop(pressed, layer[scrollarea].scrollby(0,-1));" onup="onout();" />
<layer name="scrollarea" url="%SWFPATH%/plugins/scrollarea.swf" alturl="%SWFPATH%/plugins/scrollarea.js" align="left" width="230" height="1400" zorder="1" direction="v" onhover_autoscrolling="false" onloaded="setcenter(0,0);">
<layer name="thumb-wasser-01" url="wasser-01_thumb.jpg" align="top" edge="center" x="0" y="60" onclick="hit(); loadpano(wasser-01.xml, null, MERGE, BLEND(1)); action(thumbs-zu,(); set(plugin[radar].x, 173);
set(plugin[radar].y, 210); set(plugin[radar].heading, 170.0);" />
</layer>
</layer>
<!-- galerie oeffnen schliessen -->
<layer name="thumbs-schaltf" url="schaltflaeche-l.png" keep="true" align="left" y="0" x="225" >
<layer name="thumbs-zu" url="pfeil_links.png" align="center" x="-3" visible="true" scale="0.7" onover="set(scale,1);" onout="set(scale,0.7);" onclick="action(thumbs-zu,();" />
<layer name="thumbs-auf" url="pfeil_rechts.png" align="center" x="-3" visible="false" scale="0.7" onover="set(scale,1);" onout="set(scale,0.7);" onclick="action(thumbs-auf,();" />
</layer>
<!-- small visual button hit/pressed effect -->
<action name="hit">
tween(scale, 0.9, 0.1, default, tween(scale, 1.0, 0.1, easeOutBounce));
</action>
<!-- galerie oeffnen schliessen -->
<action name="thumbs-zu">
tween(plugin[thumbs].x,-230,0.5);
tween(plugin[thumbs-schaltf].x,0,0.5);
set(plugin[thumbs-auf].visible,true);
set(plugin[thumbs-zu].visible,false);
</action>
<action name="thumbs-auf">
tween(plugin[thumbs].x,-5,0.5);
tween(plugin[thumbs-schaltf].x,225,0.5);
set(plugin[thumbs-auf].visible,false);
set(plugin[thumbs-zu].visible,true);
</action>
Display More
Ich hoffe der Code ist einigermaßen leserlich gestaltet...
Hab ich da was verbockt?
Danke schon mal für die Hilfe!
LG, Mischi