added check if 'stage.contentsScaleFactor' is available