clean and getIndexInParent for view container