Hi, i’ve got a question: how to check are container exist?

Hi, i’ve got a question: how to check are container exist? It’s very strange, but i can use for example LL.getContainerById(0x999999) and no warning or something…

4 Commentsto Hi, i’ve got a question: how to check are container exist?

  1. Check for null if you’re not sure if a container exists.

  2. So i do:

    var exist=LL.getContainerById(0x999999);

    if(exist==null){

    alert(“Null!!”);

    }else{

    alert(“Something…”);

    }

    And…Something!!! What wrong?

  3. Pierre Hébert  I consider this broken, please have a look at it

    Azariasz Trzciński As a workaround you can check for

    container.getType() == “container” && container.getOpener() == null

  4. This is because containers are created on the fly, you can create desktops and folders (or panels) this way.

    Well, I don’t think this is documented, and I am not even sure that everything is still working.

Leave a Reply

Your email address will not be published. Required fields are marked *