Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UIScreen bounds versus applicationFrame

Why do I see in some sample code from Apple (such as PhotoScroller) that I should do the following in loadView:

CGRect frame = [[UIScreen mainScreen] bounds]; 

instead of

CGRect frame = [[UIScreen mainScreen] applicationFrame]; 

Does it make a difference to get the main screen's frame?

like image 458
Joo Park Avatar asked Jun 25 '10 17:06

Joo Park


1 Answers

iOS 9 Update

When using the Split View feature on the iPad, applicationFrame returns the size of your app window. bounds always returns the size of the device.

like image 196
Code Avatar answered Oct 15 '22 16:10

Code