All Projects → numen31337 → AKGADWrapper

numen31337 / AKGADWrapper

Licence: MIT license
A wrapper for a UIViewController with a GADBannerView at the bottom

Programming Languages

objective c
16641 projects - #2 most used programming language
ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to AKGADWrapper

react-native-ad-consent
Google's User Messaging Platform (UMP SDK) for React Native.
Stars: ✭ 30 (-45.45%)
Mutual labels:  ads, admob
Godotads
Godot all in one ads module for Android. (Customizable)
Stars: ✭ 137 (+149.09%)
Mutual labels:  ads, admob
Nativescript Admob
NativeScript plugin to earn some precious 💰💰 with ads by Google AdMob
Stars: ✭ 64 (+16.36%)
Mutual labels:  banner, admob
admob
Admob for React Native with powerful hooks and components
Stars: ✭ 124 (+125.45%)
Mutual labels:  ads, admob
Admobadapter
It wraps your Adapter to display Admob native ads and banners in a ListView/RecyclerView data set. It based on the Yahoo fetchr project https://github.com/yahoo/fetchr
Stars: ✭ 224 (+307.27%)
Mutual labels:  banner, ads
Mutify
An android app built with java to mute Spotify ads.
Stars: ✭ 61 (+10.91%)
Mutual labels:  ads
AndroidModule
Android 通用模块封装
Stars: ✭ 110 (+100%)
Mutual labels:  banner
ViewWorld
自定义View合集,展示各种自定义View/控件。项目包含了自定义Banner轮播图控件,自定义验证码输入框,自定义TabLayout等控件,持续更新中😉😉😉
Stars: ✭ 94 (+70.91%)
Mutual labels:  banner
mifitxiaomipiholelist
MiFit/Xiaomi PiHole Bock List
Stars: ✭ 28 (-49.09%)
Mutual labels:  ads
SimpleSlider
A simple slider allows you to easily use.
Stars: ✭ 78 (+41.82%)
Mutual labels:  banner
react-advertising
A JavaScript library for display ads in React applications.
Stars: ✭ 50 (-9.09%)
Mutual labels:  ads
ionic3-woocommerce
Ionic 3 Woocommerce Template
Stars: ✭ 17 (-69.09%)
Mutual labels:  admob
daily-monetization
Serve ads from different providers
Stars: ✭ 29 (-47.27%)
Mutual labels:  ads
TedAdmobDialog
[Android]BackPress Ad Dialog for Admob
Stars: ✭ 37 (-32.73%)
Mutual labels:  admob
affiliate
Add affiliation tags to links automatically in the browser
Stars: ✭ 77 (+40%)
Mutual labels:  ads
banner
android 轮播图控件
Stars: ✭ 10 (-81.82%)
Mutual labels:  banner
extensions
Code Generators and Extensions for vanilla-rtb stack
Stars: ✭ 16 (-70.91%)
Mutual labels:  ads
Banner
🔥🔥🔥Android Compose Banner!!! 安卓 Compose 版本的 Banner,欢迎大家体验!!!
Stars: ✭ 40 (-27.27%)
Mutual labels:  banner
ADEasy
一套全广告平台的快速集成框架。A fast integration framework for a full advertising platform.
Stars: ✭ 79 (+43.64%)
Mutual labels:  ads
HTML5-Banners
HTML5 animated banner boilerplate. Built for Doubleclick & Sizmek ad management platforms.
Stars: ✭ 47 (-14.55%)
Mutual labels:  banner

AKGADWrapper

Platform CocoaPods

AKGADWrapper is a wrapper for a UIViewController with a GADBannerView at the bottom which automatically handles autolayout of the wrapped UIViewController. This is a very common task I stumbled upon during the development of apps that are displaying an AdMob banner.

AKVideoImageView Example

Installation

Manually and Swift

As this class uses AdMob as the external dependency, there is no way to use it while specifying use_frameworks!, because currently, AdMob is the static library itself.

In order to use this class you just need to copy AKGADWrapperVC.h and AKGADWrapperVC.m files and install SAMKeychain and Google-Mobile-Ads-SDK libraries as dependencies or connect them manually.

CocoaPods: Objective-C Only

Add the following line to your Podfile.

pod "AKGADWrapper", "~> 1.1.0"

Execute pod install.

Usage

Example of Wrapping rootViewController

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
	//Instantiate a UIViewController to wrap
	UIViewController *mainVC = [[UIStoryboard storyboardWithName:@"Main" bundle:nil] instantiateInitialViewController];
	//Instantiate a AKGADWrapperVC with UIViewController to wrap and your Ad Unit ID 
	AKGADWrapperVC *wrappedVC = [[AKGADWrapperVC alloc] initWithViewController:mainVC adUnitID:@"ca-app-pub-3940256099942544/2934735716"];
	//Optionally set targeting options
	wrappedVC.gender = GADBaseGenderMale;
	//Set as the rootViewController
	self.window.rootViewController = wrappedVC;

	/// Set the color under the banner for the frameless devices
    wrappedVC.view.backgroundColor = [UIColor redColor];
   
	return YES;
}

Removing Ads

To hide Ads call removeAds: with true for disabling them forever or false to hide the currently presented banner but present it again after the app relaunch.

[wrapper removeAds:false];

Delaying Ads Presentation

In order to improve retention during the first app usage sessions, there is showAdsAfter feature which helps you to set a delay for presenting ads only after some amount of application launches. To start presenting Ads only on the 3rd launch set this property to 2 before presenting AKGADWrapperVC instance.

wrapper.showAdsAfter = 2;

License (MIT)

Copyright (c) 2016 Oleksandr Kirichenko

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].