我採取這種代碼這個黑客會讓蘋果狂怒嗎? (會不會拒絕我的應用程序?)
Changing the background color of a UIAlertView?
UIAlertView *theAlert = [[[UIAlertView alloc] initWithTitle:@"Atention"
message: @"YOUR MESSAGE HERE", nil)
delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil] autorelease];
[theAlert show];
UILabel *theTitle = [theAlert valueForKey:@"_titleLabel"];
[theTitle setTextColor:[UIColor redColor]];
UILabel *theBody = [theAlert valueForKey:@"_bodyTextLabel"];
[theBody setTextColor:[UIColor blueColor]];
UIImage *theImage = [UIImage imageNamed:@"Background.png"];
theImage = [theImage stretchableImageWithLeftCapWidth:16 topCapHeight:16];
CGSize theSize = [theAlert frame].size;
UIGraphicsBeginImageContext(theSize);
[theImage drawInRect:CGRectMake(0, 0, theSize.width, theSize.height)];
theImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
[[theAlert layer] setContents:[theImage CGImage]];
orginally發表oxigen。
我不太確定應該在我的應用程序中使用此代碼。請問蘋果有什麼問題關於這個黑客(他們會拒絕該應用程序?)
很難看出App Store審查過程中產生的恐懼和自我審查的數量:-( – Thilo 2009-11-19 06:41:48
不要這樣做,他們會燒你的房子! – erotsppa 2009-11-19 15:18:36