|
|
|
@ -118,6 +118,7 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
|
|
|
|
|
UIAlertAction *blockAction = [UIAlertAction
|
|
|
|
|
actionWithTitle:NSLocalizedString(@"BLOCK_LIST_BLOCK_BUTTON", @"Button label for the 'block' button")
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"block")
|
|
|
|
|
style:UIAlertActionStyleDestructive
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
[self blockPhoneNumbers:phoneNumbers
|
|
|
|
@ -130,17 +131,16 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
}];
|
|
|
|
|
blockAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"block");
|
|
|
|
|
[actionSheet addAction:blockAction];
|
|
|
|
|
|
|
|
|
|
UIAlertAction *dismissAction = [UIAlertAction actionWithTitle:CommonStrings.cancelButton
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss")
|
|
|
|
|
style:UIAlertActionStyleCancel
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
if (completionBlock) {
|
|
|
|
|
completionBlock(NO);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
dismissAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss");
|
|
|
|
|
[actionSheet addAction:dismissAction];
|
|
|
|
|
[fromViewController presentAlert:actionSheet];
|
|
|
|
|
}
|
|
|
|
@ -169,6 +169,7 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
|
|
|
|
|
UIAlertAction *blockAction = [UIAlertAction
|
|
|
|
|
actionWithTitle:NSLocalizedString(@"BLOCK_LIST_BLOCK_BUTTON", @"Button label for the 'block' button")
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"block")
|
|
|
|
|
style:UIAlertActionStyleDestructive
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
[self blockGroup:groupThread
|
|
|
|
@ -181,17 +182,16 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
}];
|
|
|
|
|
blockAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"block");
|
|
|
|
|
[actionSheet addAction:blockAction];
|
|
|
|
|
|
|
|
|
|
UIAlertAction *dismissAction = [UIAlertAction actionWithTitle:CommonStrings.cancelButton
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss")
|
|
|
|
|
style:UIAlertActionStyleCancel
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
if (completionBlock) {
|
|
|
|
|
completionBlock(NO);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
dismissAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss");
|
|
|
|
|
[actionSheet addAction:dismissAction];
|
|
|
|
|
[fromViewController presentAlert:actionSheet];
|
|
|
|
|
}
|
|
|
|
@ -333,8 +333,10 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
UIAlertController *actionSheet =
|
|
|
|
|
[UIAlertController alertControllerWithTitle:title message:nil preferredStyle:UIAlertControllerStyleActionSheet];
|
|
|
|
|
|
|
|
|
|
UIAlertAction *unblockAction = [UIAlertAction
|
|
|
|
|
actionWithTitle:NSLocalizedString(@"BLOCK_LIST_UNBLOCK_BUTTON", @"Button label for the 'unblock' button")
|
|
|
|
|
UIAlertAction *unblockAction =
|
|
|
|
|
[UIAlertAction actionWithTitle:NSLocalizedString(
|
|
|
|
|
@"BLOCK_LIST_UNBLOCK_BUTTON", @"Button label for the 'unblock' button")
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"unblock")
|
|
|
|
|
style:UIAlertActionStyleDestructive
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
[BlockListUIUtils unblockPhoneNumbers:phoneNumbers
|
|
|
|
@ -347,17 +349,16 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
}];
|
|
|
|
|
unblockAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"unblock");
|
|
|
|
|
[actionSheet addAction:unblockAction];
|
|
|
|
|
|
|
|
|
|
UIAlertAction *dismissAction = [UIAlertAction actionWithTitle:CommonStrings.cancelButton
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss")
|
|
|
|
|
style:UIAlertActionStyleCancel
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
if (completionBlock) {
|
|
|
|
|
completionBlock(YES);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
dismissAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss");
|
|
|
|
|
[actionSheet addAction:dismissAction];
|
|
|
|
|
[fromViewController presentAlert:actionSheet];
|
|
|
|
|
}
|
|
|
|
@ -406,8 +407,9 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
message:message
|
|
|
|
|
preferredStyle:UIAlertControllerStyleActionSheet];
|
|
|
|
|
|
|
|
|
|
UIAlertAction *unblockAction = [UIAlertAction
|
|
|
|
|
actionWithTitle:NSLocalizedString(@"BLOCK_LIST_UNBLOCK_BUTTON", @"Button label for the 'unblock' button")
|
|
|
|
|
UIAlertAction *unblockAction = [UIAlertAction actionWithTitle:NSLocalizedString(@"BLOCK_LIST_UNBLOCK_BUTTON",
|
|
|
|
|
@"Button label for the 'unblock' button")
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"unblock")
|
|
|
|
|
style:UIAlertActionStyleDestructive
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
[BlockListUIUtils unblockGroup:groupModel
|
|
|
|
@ -420,17 +422,16 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
}];
|
|
|
|
|
unblockAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"unblock");
|
|
|
|
|
[actionSheet addAction:unblockAction];
|
|
|
|
|
|
|
|
|
|
UIAlertAction *dismissAction = [UIAlertAction actionWithTitle:CommonStrings.cancelButton
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss")
|
|
|
|
|
style:UIAlertActionStyleCancel
|
|
|
|
|
handler:^(UIAlertAction *_Nonnull action) {
|
|
|
|
|
if (completionBlock) {
|
|
|
|
|
completionBlock(YES);
|
|
|
|
|
}
|
|
|
|
|
}];
|
|
|
|
|
dismissAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"dismiss");
|
|
|
|
|
[actionSheet addAction:dismissAction];
|
|
|
|
|
[fromViewController presentAlert:actionSheet];
|
|
|
|
|
}
|
|
|
|
@ -473,9 +474,9 @@ typedef void (^BlockAlertCompletionBlock)(UIAlertAction *action);
|
|
|
|
|
[UIAlertController alertControllerWithTitle:title message:message preferredStyle:UIAlertControllerStyleAlert];
|
|
|
|
|
|
|
|
|
|
UIAlertAction *okAction = [UIAlertAction actionWithTitle:NSLocalizedString(@"OK", nil)
|
|
|
|
|
accessibilityIdentifier:SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"ok")
|
|
|
|
|
style:UIAlertActionStyleDefault
|
|
|
|
|
handler:completionBlock];
|
|
|
|
|
okAction.accessibilityIdentifier = SUBVIEW_ACCESSIBILITY_IDENTIFIER(self, @"ok");
|
|
|
|
|
[alert addAction:okAction];
|
|
|
|
|
[fromViewController presentAlert:alert];
|
|
|
|
|
}
|
|
|
|
|