From b9cb4481d9832f56000fb6be0ac53afe63a7ff18 Mon Sep 17 00:00:00 2001 From: Bidiniuc Igor Date: Mon, 24 Aug 2015 10:29:30 +0300 Subject: [PATCH] Fixed crash when is added CAKeyframeAnimation Crash occur when want to add an CAKeyframeAnimation. It's not responds to selector @fromValue. --- LMAlertView/CALayer+ModalAlert.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LMAlertView/CALayer+ModalAlert.m b/LMAlertView/CALayer+ModalAlert.m index 085311c..824f6b8 100644 --- a/LMAlertView/CALayer+ModalAlert.m +++ b/LMAlertView/CALayer+ModalAlert.m @@ -42,7 +42,7 @@ - (void)_addAnimation:(CAAnimation *)anim forKey:(NSString *)key { UIView *view = [self delegate]; UIWindow *window = [self windowForView:view]; - if ([window.rootViewController isKindOfClass:[LMEmbeddedViewController class]]) { + if ([window.rootViewController isKindOfClass:[LMEmbeddedViewController class]] && [anim isKindOfClass:[CABasicAnimation class]]) { CABasicAnimation *basicAnim = (CABasicAnimation *)anim; CGFloat modalWidth = 290.0;