Merge "Fix another layout casting crash that happens sometimes"