UIActivityIndicatorViewStyleWhiteLarge not appearing in iphone 4
-
08-10-2019 - |
Question
I tried to create an activity indicator using the following code
CGRect frame = CGRectMake(160, 160.0,40.0,40.0);
progressIndicator = [[[UIActivityIndicatorView alloc] initWithFrame:frame]autorelease];
[progressIndicator startAnimating];
progressIndicator.activityIndicatorViewStyle = UIActivityIndicatorViewStyleWhiteLarge;
progressIndicator.hidesWhenStopped=YES;
[progressIndicator sizeToFit];
[self.view addSubview:progressIndicator];
This code is working correctly in all devices except iphone 4(ie. indicator not showing in iphone 4). For that reason, i was forced to change the UIActivityIndicatorViewStyleWhiteLarge to UIActivityIndicatorViewStyleGray so that activity indicator is shown in all devices. Can anyone explain me why this happens?
Solution
hi i have the same problem as yours however, actually the indicator is shown. It may seem to be a hardware problem. I guess that the retina display can not display the white display properly with white background. because when the indicator was displayed on the black background, i could check that it worked. I hope it may help you
OTHER TIPS
The large white indicator has no drop shadow on ios 4 like it does on ios 3. I'm not sure why apple removed the shadow, but the indicator is there. You just can't see it on a white background anymore. Use the grey one, or put a background behind it.
I opened a ticket against this a week after iOS 4 came out and have yet to receive even an acknowledgment of the issue. It works in iOS < 4, broken in iOS >= 4. Doubt it'll be fixed any time soon.