Hi, this is simple example to create a layer with a picture (in this case f01.jpg placed in the root)
The layer is created when clicked other layer named "test" that is always visible.
The layer is showed ok, but to click it this layer turn off it AND too turn off the layer test. The correct action was to turn off only the new picture layer, no others layers as "test"
Please, What's wrong???
Greets,
Fernando.
Code
<krpano>
<preview type="grid(cube,128,128,512,0xCCCCCC,0xF6F6F6,0x999999);" />
<layer name="test"
type="text"
css="font-size:18px;"
align="top"
html="Show picture"
onclick="creafoto_ventana(f01,f01.jpg);"
/>
<action
name="creafoto_ventana"
scope="local"
args="nombre,fichero">
addlayer(get(nombre));
set(layer[get(nombre)].url,get(fichero));
set(layer[get(nombre)].align,center);
set(layer[get(nombre)].onclick,set(layer[get(nombre)].visible,false););
</action>
</krpano>
Display More
HTML5/Desktop - Firefox 40.0 WebGL and Flashplayer Win 11.8.800.50 Plugin
krpano 1.19-pr14