I\'d like to display a temporary message on the iPhone/iPad displaying confirmation of an action, or some quick status about some background activity.
Is there a st
I ended up creating my own class. Didn't inherit from UIAlertView. General structure is,
-(id)initWithText:(NSString *)msg {
// Create a view. Put a label, set the msg
CALayer *layer = self.layer;
layer.cornerRadius = 8.0f;
...
self.backgroundColor = [UIColor colorWithWhite:0 alpha:0.8];
[self performSelector:@selector(dismiss:) withObject:nil afterDelay:2.0];
[self setAutoresizesSubviews:FALSE];
return self;
}
- (void)dismiss:(id)sender {
// Fade out the message and destroy self
[UIView animateWithDuration:0.5
animations:^ { self.alpha = 0; }
completion:^ (BOOL finished) { [self removeFromSuperview]; }];
}