Bug fixes for removing children that are set to capture events.