2013-05-20 98 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