2013-05-20 103 views
0

我想问如何设置background image,同时加载广告直到它显示广告。在GADBannerView上设置背景图片

AdMob = [[GADBannerView alloc]init]; 
AdMob.frame = CGRectMake(0, 0 , GAD_SIZE_300x250.width, GAD_SIZE_300x250.height); 
AdMob.backgroundColor = [UIColor grayColor]; 
AdMob.adUnitID = [GlobalVariable sharedInstance].PID_IOS_PHONE; 
AdMob.rootViewController = self; 
GADRequest *request = [GADRequest request]; 
[AdMob loadRequest:request]; 

回答

3

您可以设置图片为使用波纹管一段代码背景: -

AdMob.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"Background.png"]]; 
+0

感谢@Nitin。它运作良好。 – Template09