ios - How do I fix a SubView to the bottom of screen for iPhone 4 & 5 in XCode without using AutoLayout? -
i have created subview display mobile ad in xcode project. ad loads fine , works iphone 5 not iphone 4.
i trying ad fix bottom of screen on both iphone 4 & 5 doesn't want iphone 4.
i not using auto layout , not wish - there way can programatically or using interface builder?
really stuck, seems simple please help
if frame of ad view (let name adview) set, can :
[adview setframe:cgrectmake([uiscreen mainscreen].bounds.size.width-adview.frame.size.width, [uiscreen mainscreen].bounds.size.height-adview.frame.size.height, adview.frame.size.width, adview.frame.size.height )]; edit
in case of application display status bar , should :
[adview setframe:cgrectmake([uiscreen mainscreen].bounds.size.width-adview.frame.size.width, [uiscreen mainscreen].bounds.size.height-adview.frame.size.height - [uiapplication sharedapplication].statusbarframe.size.height, adview.frame.size.width, adview.frame.size.height )];
Comments
Post a Comment