método @clickedButtonAtIndex não é chamado
quando o usuário clica em um botão noUIAlertView
aclickedButtonAtIndex
método @ deve ser chamado, no entanto, não é:
no.h
chamei oUIAlertView
protocolo:
@interface RechercherViewController : UIViewController<UIAlertViewDelegate> {
//code
}
e em.m
arquivo eu tenho isso:
-(void)requestFailed:(ASIHTTPRequest *)request
{
//quand il y aura un échec lors de l'envoie de la requête
UIAlertView *alert=[[UIAlertView alloc]initWithTitle:@"TopStation"
message :@"Your internet connexion is down"
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[alert show];
[alert release];
}
- (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex{
if (buttonIndex == 0) {
NSLog(@"buttonIndex 0");
} else if(buttonIndex == 1) {
NSLog(@"buttonIndex 1");
}
}
nada é mostrado no arquivo de log, por favor ajude, thx antecipadamente:)