[AT-SPI] Fixed unreachable condition and counting of selected children