def addChild(self, item):
if item.parent and item.parent != self:<EOL><INDENT>item.parent.removeChild(item)<EOL><DEDENT>self.children.append(item)<EOL>item.parent = self<EOL>
Add *item* as child of this item.