Created
June 10, 2014 08:21
-
-
Save Keishake/543cdcfb9ad96f16fa42 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)viewDidLoad | |
{ | |
[super viewDidLoad]; | |
// Do any additional setup after loading the view. | |
// GFIconControllerの初期化 | |
gfIconController = [[GFIconController alloc] init]; | |
// アイコンの自動更新間隔を指定(デフォルトで30秒/最短10秒) | |
[gfIconController setRefreshTiming:30]; | |
// アイコンの配置位置を設定(1個〜20個まで設置出来ます) | |
{ | |
for (int i = 0; i < 4; i++) { | |
GFIconView *iconView = [[GFIconView alloc] initWithFrame:CGRectMake(30 + i*70, 0, 50, 50)]; | |
[gfIconController addIconView:iconView]; | |
[self.iconAdView addSubview:iconView]; | |
} | |
} | |
} | |
- (void)viewDidAppear:(BOOL)animated | |
{ | |
[super viewDidAppear:animated]; | |
// アイコン広告の表示 | |
[gfIconController loadAd:GAME_FEAT_ID]; | |
} | |
- (void)viewWillDisappear:(BOOL)animated | |
{ | |
[super viewWillDisappear:animated]; | |
// アイコン広告の自動更新を停止 | |
[gfIconController stopAd]; | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment