Updated for UIDevice additions