Coder Social home page Coder Social logo

jogi / uitabbarcontroller-iads Goto Github PK

View Code? Open in Web Editor NEW
19.0 6.0 5.0 173 KB

UITabBarController category for easily adding iAds with resizable views and auto rotation support.

Home Page: http://jvashishtha.github.com/UITabBarController-iAds

Objective-C 100.00%

uitabbarcontroller-iads's Introduction

UITabBarController+iAds

Simple and easy to use UITabBarController category which adds support for displaying iAds

There are numerous shared iAds implementations out there including one from Apple. All of them require a lot of work on your side to get it work. Moreover none of the existing implementations support auto resizing of views upon display of iAd without doing significant amount of changes to the existing code. To over come this I created this category.

Support

iOS 5.0+

Usage

  1. Import UITabBarController+iAd.h in the AppDelegate and then make a call to [self.tabBarController showiAds]
  2. Implement didSelectViewController tab bar controller delegate method in AppDelegate and make a call to layoutBanner

License

Under a Creative Commons Attribution 3.0 Unported License

uitabbarcontroller-iads's People

Contributors

jogi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

uitabbarcontroller-iads's Issues

Content view problem

Pushes down my webview (inside contentView) about 20px each time I go to detail view and return to article list. I have a toolbar above the tabbar that animates in and out of view. Is this creating the problem?

How to use this project from a modalView?

I have an application structure that starts from a UITabBarController.
One of the views in the UITabBarItems will create a modalView when clicking a button.
Supposing I still want to use the shared iAd banner in that modalView, what should I do?

iAd will not load after connection issue

Hi there,
I have the impression that after a disconnection the library will not load further iAds.
Or maybe there's a timeout somewhere I can't see. Basically,

=if I start it with connection available=
the ad displays, and if I remove the connection it doesn't disappear (even by leaving the app going for some minutes)

=if I start it with connection disabled=
the ad never displays, even waiting for some minutes.

Is there any known issue, is there a timeout, or is it just the behaviour of the test iAds that Apple sends?

Thanks!

Strange behaviour with UISplitViewController

I have a tabbed app where one of the tabs includes a UISplitViewController.

As soon as I add the UITabBarController+iAd files to my project I start to get strange behaviour. The class isn't even imported anywhere and it's still being called, I know this because the NSLogs are showing in the console.

Here's what's happening to my MasterViewController:

photo 28-08-2014 17 53 37
photo 28-08-2014 17 57 07

I'm also getting some errors:

<Error>: CGContextSetCompositeOperation: invalid context 0x0. This is a serious error. This application, or a library it uses, is using an invalid context  and is thereby contributing to an overall degradation of system stability and reliability. This notice is a courtesy: please fix this problem. It will become a fatal error in an upcoming update.
<Error>: CGContextFillRects: invalid context 0x0. [same message]
<Error>: CGContextRestoreGState: invalid context 0x0. [same message]
<Error>: CGContextSaveGState: invalid context 0x0. [same message]

Any ideas?

Can we have an update for storyboards please?

I have done the following which I think is right (in AppDelegate.m), and it works:

_tabBarController = (UITabBarController *)self.window.rootViewController;
_tabBarController.delegate = self;

[self.tabBarController showiAds];

Is this correct?

Tab bounds do not resize after an ad loads

I'm not sure if my terminology is correct but basically when the first advert loads in a tab it covers the bottom of the tab contents. It stays like this until either a new ad loads or if you select a different tab and then come back to it.

Is there a way to get the tab contents to resize automatically for this first ad?

iad not clickable on ios4.2 device

hi
Sample program working good with ios simulator 5.0 onwards. But for device ios 4.2, banner is not showing but not clickable.
How to solve the above issue.

A few deprecations

I have the following:

UITabBarController+iAd.m:33:17: 'currentContentSizeIdentifier' is deprecated: first deprecated in iOS 6.0

UITabBarController+iAd.m:33:48: 'ADBannerContentSizeIdentifierPortrait' is deprecated: first deprecated in iOS 6.0

UITabBarController+iAd.m:36:48: 'ADBannerContentSizeIdentifierLandscape' is deprecated: first deprecated in iOS 6.0

UITabBarController+iAd.m:40:39: 'sizeFromBannerContentSizeIdentifier:' is deprecated: first deprecated in iOS 6.0

Ads are not displaying properly in iOS 8 in Landscape

The ads are not being aligned properly in landscape orientation and the following method isn't called at all:

- (void)didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation {
        NSLog(@"Did rotate");
    [self layoutBanner];
}

Apps compiled for iOS 7 run okay but when re-complied this issue occurs.

Layout Issues with Latest Version

Sorry to bring you more issues but the ads layout is just not right with your latest commit.

The ads now cover the tab bar in most cases and don't resize and align properly for landscape (sometimes appearing off the screen).

This occurs in iOS 7 and 8.

ios simulator screen shot 6 nov 2014 12 17 49
ios simulator screen shot 6 nov 2014 12 16 42
ios simulator screen shot 6 nov 2014 12 15 27

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.