Skip to content

Instantly share code, notes, and snippets.

@xen
Last active Jun 22, 2016
Embed
What would you like to do?
isretina.py
from objc_util import *
us = ObjCClass('UIScreen')
if us.mainScreen().scale() == 2.0:
print('Retina')
elif us.mainScreen().scale() == 3.0:
print('iPhone 6 Plus')
else:
print('Non retina')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment