objective c - different rect of view in iOS5 and iOS6 -


i have code (use landscape orientation like)

- (bool)shouldautorotatetointerfaceorientation:(uiinterfaceorientation)interfaceorientation {     return uiinterfaceorientationislandscape(interfaceorientation); } 

and code in viewdidload

cgsize viewsize = [[uiscreen mainscreen] bounds].size;  if(uiinterfaceorientationislandscape([[uiapplication sharedapplication] statusbarorientation])){     viewsize = cgsizemake(viewsize.height, viewsize.width);  } else {     viewsize = cgsizemake(viewsize.width, viewsize.height); }  rect = cgrectmake(0, 0, viewsize.width, viewsize.height); 

in ios 5 rect (x=0,y=0,width=320,height=480)

in ios 6 rect (x=0,y=0,width=480,height=320)

how fix ios 5 different rect

update

in viewdidappear ok


Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -