Layer enabled not working as expected

  • krpano 1.18.5

    I have roughly this code:

    Now when I press a button I want to disable the outermost layer using .enabled="false" then fade it out:

    Code
    <action name="skin_hidesplash">
    	set(layer[skin_splash_window].enabled, false);
    	tween(layer[skin_splash_window].alpha, 0);
    	set(contextmenu.item[ss].visible,true);
    </action>




    After running the action, the layer is gone but still receiving mouse clicks and I though that was what .enabled="false" would prevent.


    Then I changed the code to:

    Code
    <action name="skin_hidesplash">
    	set(layer[skin_splash_window].enabled, false);
    	set(layer[splash_map].enabled, false);
    	tween(layer[skin_splash_window].alpha, 0);
    	set(contextmenu.item[ss].visible,true);
    </action>


    Now, it works as desired, but disabling a child layer after the parent has been disabled should be redundant.

    What am I missing?

    Kind regards

    /Obel

    Edited once, last by Obel (December 30, 2015 at 4:18 PM).

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!