property gadgetParent

(r/o) box gadgetParent;

Typ

Zugriff

This property returns the gadget parent for this box. Since not all boxes are part of gadgets, this property returns null for those boxes that are not part of a gadget.
function GetGadgetTagFromChildBox(boxId)
{
    var gadgetTag = "";
    var box = scene.getBoxById(boxId);
    if (box)
    {
        var gadg = box.gadgetParent;
        if (gadg)
            gadgetTag = gadg.tag;
    }
}