Fix component painting/creation order