mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Add new delegate which fires when the user selected "Send Always" in the alert
This commit is contained in:
parent
e975ce9e85
commit
20dc818137
@ -139,6 +139,9 @@ typedef enum CrashReportStatus {
|
||||
// Invoked before the user is asked to send a crash report, so you can do additional actions. E.g. to make sure not to ask the user for an app rating :)
|
||||
-(void) willShowSubmitCrashReportAlert;
|
||||
|
||||
// Invoked after the user did choose to send crashes always in the alert
|
||||
-(void) userDidChooseSendAlways;
|
||||
|
||||
@end
|
||||
|
||||
@interface BWQuincyManager : NSObject <NSXMLParserDelegate> {
|
||||
|
@ -386,12 +386,21 @@ NSString *BWQuincyLocalize(NSString *stringToken) {
|
||||
case 1:
|
||||
[self _sendCrashReports];
|
||||
break;
|
||||
case 2:
|
||||
case 2: {
|
||||
[[NSUserDefaults standardUserDefaults] setBool:YES forKey:kAutomaticallySendCrashReports];
|
||||
[[NSUserDefaults standardUserDefaults] synchronize];
|
||||
if (self.delegate != nil && [self.delegate respondsToSelector:@selector(userDidChooseSendAlways)]) {
|
||||
[self.delegate userDidChooseSendAlways];
|
||||
}
|
||||
|
||||
[self _sendCrashReports];
|
||||
break;
|
||||
}
|
||||
default:
|
||||
_sendingInProgress = NO;
|
||||
[self _cleanCrashReports];
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user