From 554fb1647c97110d8ba1c4e2d4ae81927bd8b384 Mon Sep 17 00:00:00 2001 From: Ilya Grechuhin Date: Tue, 8 Nov 2016 14:48:54 +0300 Subject: [PATCH] [ios] Fixed multiple alerts display. --- .../CustomAlert/AlertController/MWMAlertViewController.mm | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/iphone/Maps/Classes/CustomAlert/AlertController/MWMAlertViewController.mm b/iphone/Maps/Classes/CustomAlert/AlertController/MWMAlertViewController.mm index 37bea44e92..111bb630e2 100644 --- a/iphone/Maps/Classes/CustomAlert/AlertController/MWMAlertViewController.mm +++ b/iphone/Maps/Classes/CustomAlert/AlertController/MWMAlertViewController.mm @@ -197,14 +197,10 @@ static NSString * const kAlertControllerNibIdentifier = @"MWMAlertViewController } [UIView animateWithDuration:kDefaultAnimationDuration animations:^{ - for (MWMAlert * view in self.view.subviews) - view.alpha = 0.0; - } - completion:^(BOOL finished) { for (MWMAlert * view in self.view.subviews) { if (view != alert) - view.hidden = YES; + view.alpha = 0.0; } }]; @@ -229,8 +225,6 @@ static NSString * const kAlertControllerNibIdentifier = @"MWMAlertViewController NSArray * subviews = self.view.subviews; MWMAlert * closeAlert = subviews.lastObject; MWMAlert * showAlert = (subviews.count >= 2 ? subviews[subviews.count - 2] : nil); - if (showAlert) - showAlert.hidden = NO; [UIView animateWithDuration:kDefaultAnimationDuration animations:^{ closeAlert.alpha = 0.;