Skip to content

Commit

Permalink
Don't resize contentFrame of a custom UIViewController on bottom ads.
Browse files Browse the repository at this point in the history
  • Loading branch information
pyrosphere committed Sep 22, 2014
1 parent 67d7e19 commit 78ae4f7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion CJPAdController/CJPAdController.m
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,9 @@ - (void)viewDidLayoutSubviews
CJPLog(@"AdView exists and ad is being shown.");

if(_adPosition==CJPAdPositionBottom){
contentFrame.size.height -= bannerFrame.size.height;
if (_isTabBar || _isNavController) {
contentFrame.size.height -= bannerFrame.size.height;
}
bannerFrame.origin.y = contentFrame.size.height;
}
else if(_adPosition==CJPAdPositionTop){
Expand Down

0 comments on commit 78ae4f7

Please sign in to comment.