How to get iAdBannerView to stretch across full wi

2019-08-12 18:51发布

Just wondering how you are supposed to stretch the iAdBannerView across the full width of the Adaptive Layout Storyboard that exists in Xcode 6.

When I try and stretch it to the corners (so I can set auto layout values), it does allow it to be stretched.

1条回答
冷血范
2楼-- · 2019-08-12 19:02

Your ADBannerView will know which device it is on and set its dimensions correctly. You should just let auto layout know where you want the ad to be. For example, if you wanted the ADBannerView to be at the bottom of the screen then pin it to the bottom of the view with Bottom Space to: Bottom Layout Guide and align it to Align Center X to: Superview.

查看更多
登录 后发表回答